Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/alicewriteswrongs/stencil-custom-elements-repro
small repro case
https://github.com/alicewriteswrongs/stencil-custom-elements-repro
Last synced: about 1 month ago
JSON representation
small repro case
- Host: GitHub
- URL: https://github.com/alicewriteswrongs/stencil-custom-elements-repro
- Owner: alicewriteswrongs
- Created: 2023-07-18T15:04:25.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-07-18T15:14:30.000Z (over 1 year ago)
- Last Synced: 2024-10-30T06:59:37.977Z (3 months ago)
- Language: TypeScript
- Size: 105 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# defineCustomElements type issue repro
This project showcases an issue with the typing for `defineCustomElements`.
The repro includes a Stencil project and a project which imports and uses that
project. The importing project includes a typescript file (`test.ts`) which typechecks
but which fails at runtime, showing that the types are not accurate!To test it out do:
```sh
npm install
npm run build
npm start
```you should see a console like like
```
Uncaught TypeError: Cannot read properties of undefined (reading 'then')
at test.js:763:25
at test.js:766:3
```even though if you open up `packages/importing-package/test.ts` you won't see
any errors in the editor.