Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[esbuild-plugin-copy] Feature request: Ability to ignore specific files #115

Open
jerrychan7 opened this issue Aug 24, 2024 · 0 comments
Open

Comments

@jerrychan7
Copy link

Thanks for the plugin!

Is it possible to copy all files in the source directory but exclude specific files?
I can think of two possible methods:

{
  from: ["./src/**/*", "./imgs/**/*"],
  to: ["./build"],
  // method 1
  ignore: ["*.ts", "*.gif"],
  // method 2
  filter: (filePath) => !filePath.endsWith(".ts") && !filePath.endsWith(".gif"),
}

Or users can be allowed to mix the two methods to achieve more fine-grained control.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant