0
正常工作,我尝试使用SweetAlert与Laravel 5.5全光照Larvel混合,但不能正常工作SweetAlert在Laravel 5.5使用laravel混合不使用CSS
webpack.mix.js
mix.js('resources/assets/js/app.js', 'public/js')
.sass('resources/assets/sass/app.scss', 'public/css')
.copy('node_modules/sweetalert/dist', 'public/js');
包。 JSON
"devDependencies": {
...
"bootstrap-sass": "^3.3.7",
...
"jquery": "^3.2",
"laravel-mix": "^1.0",
"sweetalert": "^2.0.8",
资源/资产/上海社会科学院/ app.css
// Sweet Alert
@import url("https://cdnjs.cloudflare.com/ajax/libs/sweetalert/1.1.3/sweetalert.css");
当我执行npm run dev
编译没有任何错误。
但是,当我使用这种方法时,警报将显示没有CSS样式的SweetAlert。