Skip to content

Commit

Permalink
fix(pack): function files with names whose prefix is same as other fu…
Browse files Browse the repository at this point in the history
…nction names
  • Loading branch information
vamche committed Jun 17, 2021
1 parent 06c5186 commit b20a0b8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/pack.ts
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ export async function pack(this: EsbuildPlugin) {
const filesPathList = files
.filter(({ localPath }) => {
// exclude non individual files based on file path (and things that look derived, e.g. foo.js => foo.js.map)
if (excludedFiles.find(p => localPath.startsWith(p))) return false;
if (excludedFiles.find(p => localPath.startsWith(`${p}.`))) return false;

// exclude files that belong to individual functions
if (localPath.startsWith('__only_') && !localPath.startsWith(`__only_${name}/`))
Expand Down

0 comments on commit b20a0b8

Please sign in to comment.