Open sant123 opened 2 months ago
For naming it could be:
@vanjs/core
-> Client-Side@vanjs/core-lite
-> Client-Side without state and no Document@vanjs/ssr
-> Server-SideI know there is a good reason for the current names mini-van-plate/van-plate
and mini-van-plate
however the names above could be more explanatory?
I tried to publish Mini-Van to JSR. It seems that there isn't an easy way to do that. This is the error message that I got:
Check file:///Users/xintao/org/mini-van/src/mini-van.js
Check file:///Users/xintao/org/mini-van/src/van-plate.js
Check file:///Users/xintao/org/mini-van/src/shared.js
error: TS2304 [ERROR]: Cannot find name 'Element'.
type BrowserTags = Tags<Element, Text> & {
~~~~~~~
at file:///Users/xintao/org/mini-van/src/mini-van.d.ts:46:25
TS2304 [ERROR]: Cannot find name 'Text'.
type BrowserTags = Tags<Element, Text> & {
~~~~
at file:///Users/xintao/org/mini-van/src/mini-van.d.ts:46:34
TS2304 [ERROR]: Cannot find name 'HTMLElementTagNameMap'.
[K in keyof HTMLElementTagNameMap]: TagFunc<Element, Text, HTMLElementTagNameMap[K]>
~~~~~~~~~~~~~~~~~~~~~
at file:///Users/xintao/org/mini-van/src/mini-van.d.ts:47:15
TS2304 [ERROR]: Cannot find name 'Element'.
[K in keyof HTMLElementTagNameMap]: TagFunc<Element, Text, HTMLElementTagNameMap[K]>
~~~~~~~
at file:///Users/xintao/org/mini-van/src/mini-van.d.ts:47:47
TS2304 [ERROR]: Cannot find name 'Text'.
[K in keyof HTMLElementTagNameMap]: TagFunc<Element, Text, HTMLElementTagNameMap[K]>
~~~~
at file:///Users/xintao/org/mini-van/src/mini-van.d.ts:47:56
TS2304 [ERROR]: Cannot find name 'HTMLElementTagNameMap'.
[K in keyof HTMLElementTagNameMap]: TagFunc<Element, Text, HTMLElementTagNameMap[K]>
~~~~~~~~~~~~~~~~~~~~~
at file:///Users/xintao/org/mini-van/src/mini-van.d.ts:47:62
TS2304 [ERROR]: Cannot find name 'Element'.
export interface Van extends VanObj<Element, Text> {
~~~~~~~
at file:///Users/xintao/org/mini-van/src/mini-van.d.ts:64:37
TS2304 [ERROR]: Cannot find name 'Text'.
export interface Van extends VanObj<Element, Text> {
~~~~
at file:///Users/xintao/org/mini-van/src/mini-van.d.ts:64:46
TS2304 [ERROR]: Cannot find name 'Element'.
readonly tags: BrowserTags & ((namespaceURI: string) => Tags<Element, Text>)
~~~~~~~
at file:///Users/xintao/org/mini-van/src/mini-van.d.ts:69:64
TS2304 [ERROR]: Cannot find name 'Text'.
readonly tags: BrowserTags & ((namespaceURI: string) => Tags<Element, Text>)
~~~~
at file:///Users/xintao/org/mini-van/src/mini-van.d.ts:69:73
Found 10 errors.
It looks like DOM types can't be used for packages published to JSR.
I love Deno, but to be honest I'm not really a big fan of keeping reinventing the wheel for marginal improvement.
I will revert the partial changes that I made. I can revisit the issue if an easy way to publish to JSR is discovered.
I know there is a good reason for the current names
mini-van-plate/van-plate
andmini-van-plate
however the names above could be more explanatory?
I didn't think too much while picking the name for NPM. I chose the name because this is the one that was available for me to use at that time. Later packages published to NPM follow the convention of vanjs-*
because names like that are always available to use. Once packages are published their names are really hard to change.
Hi, taking a look on https://vanjs.org/minivan#server-side-deno-integration I see useful to support VanJS on JSR.
Please see https://jsr.io/
Thanks 🙏🏼