1
0
Fork 0
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:
dengyun 2018-08-23 22:48:17 +08:00 committed by Tim Neutkens
parent a4defaa9de
commit b32763b9e3
2 changed files with 6 additions and 1 deletions

View file

@ -6,7 +6,7 @@
"import",
{
"libraryName": "antd",
"style": "less"
"style": true
}
]
]

View file

@ -1,6 +1,11 @@
/* eslint-disable */
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({
lessLoaderOptions: {
javascriptEnabled: true,