svelte-materialify icon indicating copy to clipboard operation
svelte-materialify copied to clipboard

Advanced Install not working with snowpack

Open betaboon opened this issue 3 years ago • 5 comments

When trying to use the Advanced install with snowpack, building the project runs into errors like:

[snowpack] FAILURE: Unexpected input (13:13)
11:   .s-container {
12:     width: 100%;
13:     padding: $container-padding-x;
                 ^
14:     margin-right: auto;
15:     margin-left: auto;
[snowpack] Failed to load node_modules/.pnpm/[email protected][email protected]/node_modules/svelte-materialify/src/components/Grid/Container.svelte

This seems to be due to a current limitation of snowpack, which is not yet solved. A discussion on the issue can be found here: https://github.com/snowpackjs/snowpack/discussions/1808

betaboon avatar Feb 13 '21 09:02 betaboon

@betaboon I've seen this, and also the snowpack issue you linked to - however, I don't get any errors at all. No scss is being processed it seems ...

fabien avatar Feb 22 '21 10:02 fabien

@fabien i have no clue how that happens. i gave up on trying until the linked snowpack-discussion is solved.

betaboon avatar Feb 22 '21 10:02 betaboon

Cross-posting https://github.com/TheComputerM/svelte-materialify/issues/113#issuecomment-783336224

fabien avatar Feb 22 '21 12:02 fabien

i just tested with snowpack 3.1.0-pre.6 and the (not currently released on npm) @snowpack/plugin-svelte and this seems to indeed fix the advanced installation with snowpack.

i asked in snowpackjs/snowpack#2707 if they could release the pre-version of @snowpack/plugin-svelte to npm. if that happens i will post back, as it simplifies the setup.

what i did:

  • npm install -D [email protected]
  • npm install -D svelte-hmr
  • npm link $path_to_snowpack_git_clone/plugins/plugin-svelte

betaboon avatar Feb 27 '21 14:02 betaboon

the pre-version of@snowpack/plugin-svelte is now available on npm. so the advanced installation now works when using snowpack@next and @snowpack/plugin-svelte@next

as soon as snowpack 3.1.0 is released i will create a PR to document the snowpack installation :)

betaboon avatar Feb 28 '21 10:02 betaboon