Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Demo Sass capabilities in with-next-sass example #11674

Closed
wants to merge 2 commits into from
Closed

Demo Sass capabilities in with-next-sass example #11674

wants to merge 2 commits into from

Conversation

nicholaschiang
Copy link
Contributor

This addresses #11610 by demoing the recently implemented fix in the official with-next-sass example.

I've used Google's MDC @material/typography package to demonstrate some common Sass functionality:

  • @use and @include statements for scoped SCSS modules
  • @use for including global Sass styling

I'd also strongly suggest updating your website's Sass documentation with a link to this example. And make it clear what the best way to use Sass is (i.e. using @zeit/next-sass or the out-of-box stuff) as described in this issue.

@@ -1,5 +1,8 @@
@use '@material/typography';
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The includePaths option is not needed if you prefix it with ~ right 🤔

Suggested change
@use '@material/typography';
@use '~@material/typography';

That opts in the file for module resolution through webpack

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nope, because the Sass modules that I'm using have their own imports (that do not use the ~ in their @use statements).

I don't want to mess with my dependencies's source code.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems like those modules are not working in the general ecosystem overall then?

@timneutkens timneutkens added the examples Issue/PR related to examples label Apr 5, 2020
@Timer
Copy link
Member

Timer commented May 18, 2020

Closing due to inactivity. Feel free to reopen with an updated example / feedback above addressed. Thanks!

@Timer Timer closed this May 18, 2020
@vercel vercel locked as resolved and limited conversation to collaborators Jan 30, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
examples Issue/PR related to examples
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants