Next.js: SASS hot-reloading on with-external-scoped-css example

Created on 7 Jul 2017  ยท  2Comments  ยท  Source: vercel/next.js

  • [x] I have searched the issues of this repository and believe that this is not a duplicate.

Hello guys!

First things first: thanks a lot to the contributors for the framework : )

I'm contacting because I'm having hard times trying to hot-reload the .sass on this example: https://github.com/zeit/next.js/tree/v3-beta/examples/with-external-scoped-css

My goal is to have a folder per component / page, with a hot-reloaded js and scss file, using scoped css, and without adding <style dangerouslySetInnerHTML /> on every component or without using template string kind of css technology as style-jsx or styled-components.

โ”œโ”€โ”€ comp1
โ”‚ย ย  โ”œโ”€โ”€ index.js
โ”‚ย ย  โ””โ”€โ”€ styles.scss
โ”œโ”€โ”€ comp2
โ”‚ย ย  โ”œโ”€โ”€ index.js
โ”‚ย ย  โ””โ”€โ”€ styles.scss
โ””โ”€โ”€ comp3
    โ””โ”€โ”€ index.js
    โ””โ”€โ”€ styles.scss

So the thing is that there's a related PR mentioned in the example as a potential fix for the hot-reloading ( https://github.com/zeit/next.js/pull/823), and I was wondering if anybody has any example / tip on how the functionality added by the PR could be used to customize the hot-reloading so the changes on the sass are also detected and injected.

I have tried and tested a lot without success, including the approached on this thread, but none is fitting completely what I want to achieve, so any help would be really appreciated.

Thanks a lot in advance!!

All 2 comments

So the thing is that there's a related PR mentioned in the example as a potential fix for the hot-reloading ( #823), and I was wondering if anybody has any example / tip on how the functionality added by the PR could be used to customize the hot-reloading so the changes on the sass are also detected and injected.

this actually doesn't fix the issue you're having ๐Ÿ˜ข

Lets track this in #1615 and https://github.com/zeit/next.js/issues/1245

Was this page helpful?
0 / 5 - 0 ratings

Related issues

rauchg picture rauchg  ยท  3Comments

olifante picture olifante  ยท  3Comments

sospedra picture sospedra  ยท  3Comments

ghost picture ghost  ยท  3Comments

YarivGilad picture YarivGilad  ยท  3Comments