Created
April 15, 2020 08:59
-
-
Save GreatWizard/8a5b30d21a1d7273bb92f29f0e28c521 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict' | |
const Funnel = require('broccoli-funnel') | |
const mergeTrees = require('broccoli-merge-trees') | |
module.exports = { | |
name: require('./package').name, | |
treeForPublic(tree) { | |
let trees = [] | |
if (tree) { | |
trees.push(tree) | |
} | |
trees.push( | |
new Funnel('node_modules/my-package/dist', { | |
include: ['**/*.js', '**/*.svg'], | |
destDir: '/assets/my-package/' | |
}) | |
) | |
return mergeTrees(trees, { | |
overwrite: true | |
}) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment