Skip to content

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

Description

@jerrychan7

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.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions