我已将Ionic更新到最新版本4.5.0,并且出现此错误:
ERROR in ./src/theme/variables.scss (./node_modules/@angular-devkit/build-angular/src/angular-cli-files/plugins/raw-css-loader.js!./node_modules/postcss-loader/src??embedded!./node_modules/sass-loader/lib/loader.js??ref--14-3!./src/theme/variables.scss)
[ng] Module build failed (from ./node_modules/postcss-loader/src/index.js):
[ng] BrowserslistError: Unknown browser query `basedir=$(dirname "$(echo "$0" | sed -e 's`. Maybe you are using old Browserslist or made typo in query.
[ng] at unknownQuery (C:\Users\Feaxer\Desktop\myApp\node_modules\browserslist\index.js:129:10)
[ng] at C:\Users\Feaxer\Desktop\myApp\node_modules\browserslist\index.js:187:11
[ng] at Array.reduce (<anonymous>)
[ng] at resolve (C:\Users\Feaxer\Desktop\myApp\node_modules\browserslist\index.js:136:18)
[ng] at browserslist (C:\Users\Feaxer\Desktop\myApp\node_modules\browserslist\index.js:252:16)
[ng] at Browsers.parse (C:\Users\Feaxer\Desktop\myApp\node_modules\autoprefixer\lib\browsers.js:66:12)
[ng] at new Browsers (C:\Users\Feaxer\Desktop\myApp\node_modules\autoprefixer\lib\browsers.js:48:26)
[ng] at loadPrefixes (C:\Users\Feaxer\Desktop\myApp\node_modules\autoprefixer\lib\autoprefixer.js:85:20)
[ng] at plugin (C:\Users\Feaxer\Desktop\myApp\node_modules\autoprefixer\lib\autoprefixer.js:96:20)
[ng] at LazyResult.run (C:\Users\Feaxer\Desktop\myApp\node_modules\postcss\lib\lazy-result.js:295:14)
[ng] at LazyResult.asyncTick (C:\Users\Feaxer\Desktop\myApp\node_modules\postcss\lib\lazy-result.js:208:26)
[ng] at LazyResult.asyncTick (C:\Users\Feaxer\Desktop\myApp\node_modules\postcss\lib\lazy-result.js:221:14)
[ng] at C:\Users\Feaxer\Desktop\myApp\node_modules\postcss\lib\lazy-result.js:213:17
[ng] ERROR in ./src/global.scss (./node_modules/@angular-devkit/build-angular/src/angular-cli-files/plugins/raw-css-loader.js!./node_modules/postcss-loader/src??embedded!./node_modules/sass-loader/lib/loader.js??ref--14-3!./src/global.scss)
[ng] Module build failed (from ./node_modules/postcss-loader/src/index.js):
[ng] BrowserslistError: Unknown browser query `basedir=$(dirname "$(echo "$0" | sed -e 's`. Maybe you are using old Browserslist or made typo in query.
[ng] at unknownQuery (C:\Users\Feaxer\Desktop\myApp\node_modules\browserslist\index.js:129:10)
[ng] at C:\Users\Feaxer\Desktop\myApp\node_modules\browserslist\index.js:187:11
[ng] at Array.reduce (<anonymous>)
[ng] at resolve (C:\Users\Feaxer\Desktop\myApp\node_modules\browserslist\index.js:136:18)
[ng] at browserslist (C:\Users\Feaxer\Desktop\myApp\node_modules\browserslist\index.js:252:16)
[ng] at Browsers.parse (C:\Users\Feaxer\Desktop\myApp\node_modules\autoprefixer\lib\browsers.js:66:12)
[ng] at new Browsers (C:\Users\Feaxer\Desktop\myApp\node_modules\autoprefixer\lib\browsers.js:48:26)
[ng] at loadPrefixes (C:\Users\Feaxer\Desktop\myApp\node_modules\autoprefixer\lib\autoprefixer.js:85:20)
[ng] at plugin (C:\Users\Feaxer\Desktop\myApp\node_modules\autoprefixer\lib\autoprefixer.js:96:20)
[ng] at LazyResult.run (C:\Users\Feaxer\Desktop\myApp\node_modules\postcss\lib\lazy-result.js:295:14)
[ng] at LazyResult.asyncTick (C:\Users\Feaxer\Desktop\myApp\node_modules\postcss\lib\lazy-result.js:208:26)
[ng] at LazyResult.asyncTick (C:\Users\Feaxer\Desktop\myApp\node_modules\postcss\lib\lazy-result.js:221:14)
[ng] at C:\Users\Feaxer\Desktop\myApp\node_modules\postcss\lib\lazy-result.js:213:17
[ng] ERROR in ./src/app/home/home.page.scss
[ng] Module build failed (from ./node_modules/postcss-loader/src/index.js):
[ng] BrowserslistError: Unknown browser query `basedir=$(dirname "$(echo "$0" | sed -e 's`. Maybe you are using old Browserslist or made typo in query.
[ng] at unknownQuery (C:\Users\Feaxer\Desktop\myApp\node_modules\browserslist\index.js:129:10)
[ng] at C:\Users\Feaxer\Desktop\myApp\node_modules\browserslist\index.js:187:11
[ng] at Array.reduce (<anonymous>)
[ng] at resolve (C:\Users\Feaxer\Desktop\myApp\node_modules\browserslist\index.js:136:18)
[ng] at browserslist (C:\Users\Feaxer\Desktop\myApp\node_modules\browserslist\index.js:252:16)
[ng] at Browsers.parse (C:\Users\Feaxer\Desktop\myApp\node_modules\autoprefixer\lib\browsers.js:66:12)
[ng] at new Browsers (C:\Users\Feaxer\Desktop\myApp\node_modules\autoprefixer\lib\browsers.js:48:26)
[ng] at loadPrefixes (C:\Users\Feaxer\Desktop\myApp\node_modules\autoprefixer\lib\autoprefixer.js:85:20)
[ng] at plugin (C:\Users\Feaxer\Desktop\myApp\node_modules\autoprefixer\lib\autoprefixer.js:96:20)
[ng] at LazyResult.run (C:\Users\Feaxer\Desktop\myApp\node_modules\postcss\lib\lazy-result.js:295:14)
[ng] at LazyResult.asyncTick (C:\Users\Feaxer\Desktop\myApp\node_modules\postcss\lib\lazy-result.js:208:26)
[ng] at LazyResult.asyncTick (C:\Users\Feaxer\Desktop\myApp\node_modules\postcss\lib\lazy-result.js:221:14)
[ng] at C:\Users\Feaxer\Desktop\myApp\node_modules\postcss\lib\lazy-result.js:213:17
[ng] at process._tickCallback (internal/process/next_tick.js:68:7)
[ng] ERROR in ./ansi-html 1:0
[ng] Module parse failed: Unexpected character '#' (1:0)
[ng] You may need an appropriate loader to handle this file type.
[ng] > #!/bin/sh
[ng] | basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
[ng] |
离子:
ionic (Ionic CLI) : 4.5.0 (C:\Windows\System32\node_modules\ionic)
Ionic Framework : ionic/angular 4.0.0-beta.17
angular-devkit/build-angular : 0.10.7
angular-devkit/schematics : 7.0.7
angular/cli : 7.0.7
ionic/angular-toolkit : 1.2.0
系统:
NodeJS : v10.14.2 (C:\Program Files\nodejs\node.exe)
npm : 6.4.1
OS : Windows 10
为什么会出现此错误?