Closed GeometryRamiroGarcia closed 5 years ago
Try using a recursive glob syntax in your source folder:
mix.pug('resources/assets/pug/**/*.pug', 'resources/views/', {
ext: '.blade.php',
exludePath: 'resources/assets/pug/'
});
Hello! Can you change exludePath to excludePath in readme? Thank you!
same thing and same code got this error: 👇
Pug Compilation Failed!
Error: ENOENT: no such file or directory, open 'D:\Code\laravelm\resources\markup\resources\views\index.pug'
Pug Compilation Failed!
Error: ENOENT: no such file or directory, open 'D:\Code\laravelm\resources\markup\layout-blocks\resources\views\layout_sign.pug'
Pug Compilation Failed!
Error: ENOENT: no such file or directory, open 'D:\Code\laravelm\resources\markup\layout-blocks\resources\views\layout.pug'
Pug Compilation Failed!
Error: ENOENT: no such file or directory, open 'D:\Code\laravelm\resources\markup\sign\resources\views\signin_form.pug'
Pug Compilation Failed!
Error: ENOENT: no such file or directory, open 'D:\Code\laravelm\resources\markup\sign\resources\views\signup_form.pug'
Pug Compilation Failed!
Error: ENOENT: no such file or directory, open 'D:\Code\laravelm\resources\markup\resources\views\signin.pug'
Pug Compilation Failed!
Error: ENOENT: no such file or directory, open 'D:\Code\laravelm\resources\markup\resources\views\signup.pug'
internal/fs/utils.js:230
throw err;
^
Error: ENOENT: no such file or directory, stat 'D:\Code\laravelm\resources\markup\layout-blocks\resources\views\layout.pug'
at Object.statSync (fs.js:932:3)
at Object.statSync (D:\Code\laravelm\node_modules\graceful-fs\polyfills.js:308:16)
at File.size (D:\Code\laravelm\node_modules\laravel-mix\src\File.js:33:19)
at Object.size (D:\Code\laravelm\node_modules\laravel-mix\src\webpackPlugins\CustomTasksPlugin.js:43:35)
at D:\Code\laravelm\node_modules\webpack\lib\Stats.js:415:20
at Array.map (<anonymous>)
at Stats.toJson (D:\Code\laravelm\node_modules\webpack\lib\Stats.js:412:6)
at Stats.toString (D:\Code\laravelm\node_modules\webpack\lib\Stats.js:857:20)
at compilerCallback (D:\Code\laravelm\node_modules\webpack-cli\bin\cli.js:333:32)
at D:\Code\laravelm\node_modules\webpack-cli\bin\cli.js:359:7
at finalCallback (D:\Code\laravelm\node_modules\webpack\lib\Compiler.js:257:39)
at D:\Code\laravelm\node_modules\webpack\lib\Compiler.js:306:14
at AsyncSeriesHook.eval [as callAsync] (eval at create (D:\Code\laravelm\node_modules\tapable\lib\HookCodeFactory.js:33:10), <anonymous>:58:1)
at AsyncSeriesHook.lazyCompileHook (D:\Code\laravelm\node_modules\tapable\lib\Hook.js:154:20)
at D:\Code\laravelm\node_modules\webpack\lib\Compiler.js:304:22
at Compiler.emitRecords (D:\Code\laravelm\node_modules\webpack\lib\Compiler.js:499:39)
at D:\Code\laravelm\node_modules\webpack\lib\Compiler.js:298:10
at D:\Code\laravelm\node_modules\webpack\lib\Compiler.js:485:14
at AsyncSeriesHook.eval [as callAsync] (eval at create (D:\Code\laravelm\node_modules\tapable\lib\HookCodeFactory.js:33:10), <anonymous>:18:1)
at AsyncSeriesHook.lazyCompileHook (D:\Code\laravelm\node_modules\tapable\lib\Hook.js:154:20)
at D:\Code\laravelm\node_modules\webpack\lib\Compiler.js:482:27
at D:\Code\laravelm\node_modules\neo-async\async.js:2818:7
at done (D:\Code\laravelm\node_modules\neo-async\async.js:3522:9)
at AsyncSeriesHook.eval [as callAsync] (eval at create (D:\Code\laravelm\node_modules\tapable\lib\HookCodeFactory.js:33:10), <anonymous>:4:1)
at D:\Code\laravelm\node_modules\webpack\lib\Compiler.js:464:33
at D:\Code\laravelm\node_modules\graceful-fs\graceful-fs.js:61:14
If I execute the command
npm run dev
as wellresources/assets/pug/welcome.pug
work and generate
resources/views/welcome.balde.php
But If I execute the command
npm run dev
as well whit folderresources/assets/pug/welcome.pug resources/assets/pug/layouts/app.pug
don't work
generate resources/views/welcome.balde.php
no generate resources/views/layout/app.balde.php