翠 / green

Results 246 comments of 翠 / green

To workaround, add this plugin: ```js const preserveRefPlugin = () => { const preverseRefFunc = ` function __preserveRef(key, v) { if (import.meta.env.PROD) return v; import.meta.hot.data ??= {} import.meta.hot.data.contexts ??= {}...

@adnanalbeda > If this works, then I think it's possible to do a more complete implementation for it, so it can be more generic and less needing for calling `__preserveRef`....

It still happens for me. Open `src/CountProvider.jsx` and edit that file (not other files). https://stackblitz.com/edit/github-6861mq-6f4ezn?file=src%2FCountProvider.jsx

I was trying on stackblitz. But I tried it now with local and it happened.

If it's in JS, I think `import url from './something.js?url'` could be used for now. @Menci For example for your plugin, I guess this part https://github.com/Menci/vite-plugin-wasm/blob/d98e0384950b6aea3156031a17ae65d28bbc7abd/src/index.ts#L37-L57 could be like ```js...

I think this is expected. `/docs` is outside of `/docs/`. That said, IMHO changing the message to below would be friendly. ```md did you mean to visit [/docs/docs](http://localhost:3000/docs/docs) or [/docs/](http://localhost:3000/docs/)...

In URL spec, `http://localhost:3000` is equivalent to `http://localhost:3000/`, but `http://localhost:3000/docs` is not equivalent to `http://localhost:3000/docs/`. ```js new URL('http://localhost:3000').href === new URL('http://localhost:3000/').href // true new URL('http://localhost:3000/docs').href === new URL('http://localhost:3000/docs/').href // false...

I understand that but it is confusing if `/docs` returns the content of `/docs/`. I think it is ok to change the message. Maybe it is not confusing if the...

> It's still meaningless for an end user to understand the difference between /docs/ and /docs? Why should they care about that? I think it is not completely meaningless but...

Looks like it's an upstream issue since it happens not only with Vite. https://github.com/vuejs/core/issues/5767#issuecomment-1104467887