This package contains wesl source texts useful for tool builders to verify WESL parsing and linking.
The source texts are published as an array of objects in both JSON and TypeScript format. The format is described in: TestSchema.ts
JSON version: importCases.json importSyntaxCases.json conditionalTranslation.json
TypeScript version: ImportCases.ts ImportSyntaxCases.ts ConditionalTranslation.ts
Author new examples in TypeScript. (TypeScript is similar to JSON but a little more user friendly for authoring.)
A tool is included in the package to convert the TypeScript objects to JSON.
pnpm install
pnpm cases
pnpm cases:watch
Except where noted (below and/or in individual files), all code in this repository is dual-licensed under either:
- MIT License (LICENSE-MIT or http://opensource.org/licenses/MIT)
- Apache License, Version 2.0 (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
at your option.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.