Vueアプリでmath SASSライブラリを動作させるのに問題があります。これはDart Sassとsass-loaderでコンパイルされます。Dart Sassのバージョンは なので1.26.3
、mathモジュールすべき仕事。
Module build failed (from ./node_modules/sass-loader/dist/cjs.js):
SassError: There is no module with the namespace "math".
@for $i from 2 through 10
&:nth-child(#{$i}) { transition-duration: 300ms + $i * 50ms - 400ms * math.floor($i / 8); }
^^^^^^^^^^^^^^^^^^
}
- ダートサス: v1.26.3 (https://www.npmjs.com/package/sass)
- Sassローダー: v8.0.2 (https://www.npmjs.com/package/sass-loader)
ベストアンサー1
分かりました。追加する必要がありました
@use 'sass:math';
ファイルの先頭にあります。