You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Vite 3.1.0 just got released, and won't run any projects with solid-dnd included. Downgrading to 3.0.9 works fine still though.
Not sure if it's a Vite thing, or something that was in solid-dnd that Vite just let slip until now? Seems Vite-y, as it's complaining about JSX, but the file is clearly .jsx? I figured I'd report here just in case.
Failed to parse source for import analysis because the content contains invalid JS syntax. If you are using JSX, make sure to name the file with the .jsx or .tsx extension.
/Development/Web/project/node_modules/@thisbeyond/solid-dnd/dist/source/sortable-context.jsx:41:35
39 | return <Context.Provider value={context}>{props.children}</Context.Provider>;
40 | };
41 | const useSortableContext = () => {
| ^
42 | return useContext(Context) || null;
43 | };
As far as I can tell, to replicate, just update any project using vite + solid-dnd to vite@3.1.0.
Also reported to Vite here in case they have pointers on how to fix. Interestingly it does not seem to occur for my other Solid project (solid-select).
Activity
martinpengellyphillips commentedon Sep 7, 2022
Confirming this still happens with latest 0.7.0 release and Solid JS 1.5+
Looks like other packages in the Solid ecosystem are affected too.
martinpengellyphillips commentedon Sep 12, 2022
Also reported to Vite here in case they have pointers on how to fix. Interestingly it does not seem to occur for my other Solid project (solid-select).
martinpengellyphillips commentedon Sep 14, 2022
See also solidjs/solid-vite-plugin#51
martinpengellyphillips commentedon Sep 15, 2022
PR to
vite-plugin-solidissued. However, with that fix we will face a new issue with Vite: vitejs/vite#10087 (comment)martinpengellyphillips commentedon Oct 7, 2022
Closing as this should be resolved on latest of vite and vite-plugin-solid.
You may still need to add the following to your vite config though to avoid other errors: