Repository navigation
Breaking and behavior changes
- The package is an ES module only (#563). The CommonJS build,
dist/pwc.cjs, and its.d.ctstypings are gone.require('@playcanvas/web-components')works on Node 22.12 and later, which load the ES module. Jest in CommonJS mode and older Node versions get Node's error that the package is an ES module. The script-tag builds are unchanged. - Asset and material ids are looked up in the element's own
<pc-app>first, then in its own tree (#559). Two applications can now reuse an id, and an application inside a shadow root resolves its own assets and materials. An application in a shadow root no longer falls back to an id declared in the document outside it.AssetElement.getreturnsundefined, as documented, where it returnednullfor an asset not yet created. - A dotted animation track name is renamed, not skipped (#561). Under a bare
<pc-anim>, a track such asArmature|mixamo.com|Layer0is assigned asArmature|mixamo_com|Layer0and plays. - Element properties are declared as properties in the typings, not accessor pairs (#558). A TypeScript subclass that overrides one with an accessor, or reaches it through
super, no longer compiles. Reading and writing properties is unaffected.
Smaller
- The minified ES module is 144 KB, down from 211 KB (41 KB gzipped, down from 52 KB) (#558).
What's Changed
- Drop the starter count from the README by @willeastcott in #554
- docs: point coding agents at the llms.txt indexes by @willeastcott in #555
- Add an Ocean Assault example: a vertical shooter drawn from one sprite sheet by @willeastcott in #557
- Update all npm dependencies by @renovate[bot] in #556
- Declare element attributes in a schema by @willeastcott in #558
- Look for an asset or material id in the element's own app, then its own tree by @willeastcott in #559
- Play animated models in the sound examples, and host dotted track names in pc-anim by @willeastcott in #561
- Drop the CommonJS build [BREAKING] by @willeastcott in #563
Full Changelog: v0.30.0...v0.31.0