mirror of
https://github.com/terribleplan/next.js.git
synced 2024-01-19 02:48:18 +00:00
fix: SyntaxError @import "./themes/default" (#5018)
fix: bug 🐞 ![image](https://user-images.githubusercontent.com/37728280/44520939-05929380-a704-11e8-9e7e-7acbc08c6d39.png)
This commit is contained in:
parent
a4defaa9de
commit
b32763b9e3
|
@ -6,7 +6,7 @@
|
||||||
"import",
|
"import",
|
||||||
{
|
{
|
||||||
"libraryName": "antd",
|
"libraryName": "antd",
|
||||||
"style": "less"
|
"style": true
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
]
|
]
|
||||||
|
|
|
@ -1,6 +1,11 @@
|
||||||
/* eslint-disable */
|
/* eslint-disable */
|
||||||
const withLess = require('@zeit/next-less')
|
const withLess = require('@zeit/next-less')
|
||||||
|
|
||||||
|
// fix: prevents error when .less files are required by node
|
||||||
|
if (typeof require !== 'undefined') {
|
||||||
|
require.extensions['.less'] = (file) => {}
|
||||||
|
}
|
||||||
|
|
||||||
module.exports = withLess({
|
module.exports = withLess({
|
||||||
lessLoaderOptions: {
|
lessLoaderOptions: {
|
||||||
javascriptEnabled: true,
|
javascriptEnabled: true,
|
||||||
|
|
Loading…
Reference in a new issue