Hence I can't use a filter like file => file.endsWith('.js') because that excludes directories that don't end with .js.
The docs only mention files:
filter : Function to filter copied files. Return true to include, false to exclude. Can also return a Promise that resolves to true or false (or pass in an async function).
However when I log what the filter gets called with, it gets called with directories.
Hence I can't use a filter like
file => file.endsWith('.js')because that excludes directories that don't end with.js.The docs only mention files:
However when I log what the filter gets called with, it gets called with directories.