van
van copied to clipboard
Update Van JSX
@cqh963852
Seems like the van-jsx is behind on npm.
I'm getting:
error TS2322: Type 'State<string>' is not assignable to type 'string'
when trying
const state = van.state("")
<input value={state} onchange={e => state.val = e.target.value} />
which seems to be fixed here
currently using a workaround by having this in my package.json
:
{
...
"vanjs-jsx": "https://gitpkg.now.sh/vanjs-org/van/addons/van_jsx?main"
}
and with the current version in main
branch it seems to work without ts
errors.
@cqh963852, could you take a look at this issue?
@ravensiris I have create a refactor PR . PTAL
Hi @ravensiris,
The PR was merged. You can upgrade vanjs-jsx
to 0.2.0
to use the updated implementation.
Hi @ravensiris, there are some errors when I was refresh the page.
Hi @ravensiris, there are some errors when I was refresh the page.
It seems a wrong import. let me fix this.