Skip to content

Commit 2b623f7

Browse files
committed
minor #442 Improve copyFiles method examples (kapiwko)
This PR was merged into the master branch. Discussion ---------- Improve `copyFiles` method examples - add ./assets prefix to path - add missing `{` Commits ------- d949d19 Improve `copyFiles` method examples
2 parents ba99646 + d949d19 commit 2b623f7

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

index.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -432,27 +432,27 @@ class Encore {
432432
* For example:
433433
*
434434
* // Copy the content of a whole directory and its subdirectories
435-
* Encore.copyFiles({ from: './images' });
435+
* Encore.copyFiles({ from: './assets/images' });
436436
*
437437
* // Only copy files matching a given pattern
438-
* Encore.copyFiles({ from: './images', pattern: /\.(png|jpg|jpeg)$/ })
438+
* Encore.copyFiles({ from: './assets/images', pattern: /\.(png|jpg|jpeg)$/ })
439439
*
440440
* // Set the path the files are copied to
441441
* Encore.copyFiles({
442-
* from: './images',
442+
* from: './assets/images',
443443
* pattern: /\.(png|jpg|jpeg)$/,
444444
* to: 'assets/images/[path][name].[ext]'
445445
* })
446446
*
447447
* // Version files
448-
* Encore.copyFiles(
449-
* from: './images',
448+
* Encore.copyFiles({
449+
* from: './assets/images',
450450
* to: 'assets/images/[path][name].[hash:8].[ext]'
451451
* })
452452
*
453453
* // Add multiple configs in a single call
454454
* Encore.copyFiles([
455-
* { from: './images' },
455+
* { from: './assets/images' },
456456
* { from: './txt', pattern: /\.txt$/ },
457457
* ]);
458458
*

0 commit comments

Comments
 (0)