ionic-team / stencil-ds-output-targets

These are output targets that can be added to Stencil for React and Angular.
https://stenciljs.com
MIT License
249 stars 112 forks source link

bug: modelProp is string or undefined, and type 'undefined' cannot be used #280

Open iChengbo opened 2 years ago

iChengbo commented 2 years ago

Prerequisites

Stencil Version

2.13.0

Stencil Framework Output Target

Vue

Stencil Framework Output Target Version

0.6.2

Current Behavior

src/vue-component-lib/utils.ts(71,32): error TS2538: Type 'undefined' cannot be used src/vue-component-lib/utils.ts(80,49): error TS2538: Type 'undefined' cannot be used src/vue-component-lib/utils.ts(122,30): error TS2538: Type 'undefined' cannot be used

Expected Behavior

fix error

Steps to Reproduce

Follow the steps https://stenciljs.com/docs/vue

Code Reproduction URL

https://github.com/iChengbo/wcplayer/tree/main/packages/wcplayer-components-vue

Additional Information

No response

rwaskiewicz commented 2 years ago

Hey @iChengbo 👋

I'm unable to reproduce this by following the provided "Steps to Reproduce", and am unable to build the reproduction URL by running pnpm run build. To move forward with this issue, can you please add reproduction steps for the attached GitHub repo? Thanks!

ionitron-bot[bot] commented 2 years ago

Thanks for the issue! This issue has been labeled as needs reproduction. This label is added to issues that need a code reproduction.

Please reproduce this issue in a Stencil project and provide a way for us to access it (GitHub repo, etc). Without a reliable code reproduction, it is unlikely we will be able to resolve the issue, leading to it being closed.

If you have already provided a code snippet and are seeing this message, it is likely that the code snippet was not enough for our team to reproduce the issue.

rwaskiewicz commented 1 year ago

I was able to reproduce this by setting strictNullChecks to true in the root level tsconfig. Going to label this to get it ingested into our backlog

andresgutgon commented 6 months ago

I guess is because all that code is outside tsconfig included files

image