Qwik output doesn't emit mutable() as Qwik requires
- Dominant language
- TypeScript
- Stars
- 14.4k
- Forks
- 671
- PR merge metrics
- No merged PRs in 30d
Description
### I am interested in helping provide a fix!
No
### Which generators are impacted?
- [ ] All
- [ ] Angular
- [ ] HTML
- [X] Qwik
- [ ] React
- [ ] React-Native
- [ ] Solid
- [ ] Stencil
- [ ] Svelte
- [ ] Vue
- [ ] Web components
### Reproduction case
https://github.com/kylecordes/qwik-lib-repro
### Expected Behaviour
Note that the above repro does not call Mitosis. It just has the Mitosis output for Qwik pasted in.
To see it generated and fail in context, look at E2E PR #589
In this repro repo:
```
cd example-lib
npm i
npm run dev
```
... should operate without error
### Actual Behaviour
The application renders, but then when you click to add an entry, it fails with:
```
Error: Code(19): Props are immutable by default.
```
### Additional Information
Mitosis fiddle doesn't currently have Qwik output, otherwise I'd repro there instead.
Contributor guide
Research direction
Start with the Qwik output shown in the linked reproduction repository and compare it with the behavior required by Qwik when clicking to add an entry. Run `npm i` and `npm run dev` in `example-lib`, then review E2E PR #589 for the generated-output context. Done means the reproduced application operates without the immutable-props error and emits the required `mutable()` usage.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- compilers, frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100