mirror of
https://github.com/youzan/vant.git
synced 2025-10-18 09:24:25 +00:00
feat(cli): less-loader resolve node_modules
This commit is contained in:
@@ -1,8 +1,10 @@
|
||||
// @ts-ignore
|
||||
import FriendlyErrorsPlugin from '@nuxt/friendly-errors-webpack-plugin';
|
||||
import sass from 'sass';
|
||||
import { resolve } from 'path';
|
||||
import { VueLoaderPlugin } from 'vue-loader';
|
||||
import {
|
||||
CWD,
|
||||
STYLE_EXTS,
|
||||
SCRIPT_EXTS,
|
||||
POSTCSS_CONFIG_FILE
|
||||
@@ -56,7 +58,15 @@ export const baseConfig = {
|
||||
{
|
||||
test: /\.less$/,
|
||||
sideEffects: true,
|
||||
use: [...CSS_LOADERS, 'less-loader']
|
||||
use: [
|
||||
...CSS_LOADERS,
|
||||
{
|
||||
loader: 'less-loader',
|
||||
options: {
|
||||
paths: [resolve(CWD, 'node_modules')]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
test: /\.scss$/,
|
||||
|
Reference in New Issue
Block a user