Closed happyhunter7 closed 3 years ago
The problem I remember from previous versions of next.js is that you must import the css file using the require syntax in _app.js
or somewhere, else it won't work on prod. This may be a node server syntax issue, I'm not sure why at the moment, I'll deal with it later.
Hi @SolidZORO , I have a problem I want to import other .less filess.... In development mode using this syntax, it works
import './my-path/my-styles.less'
But when building the project these styles are not built and present in the build folder....also no errors appears.Another interesting thing.....it works only when I'm using
require('./my-path/my-styles.less')
.So why it works with
require
but not withimport
? And how to fix it??