@fnet/rollup-plugin-delete
v0.1.2
Published
The **@fnet/rollup-plugin-delete** project is a plugin for Rollup, a popular module bundler used in JavaScript projects. This plugin is used to delete files and directories in your project as a part of the Rollup build process.
Downloads
96
Readme
@fnet/rollup-plugin-delete
The @fnet/rollup-plugin-delete project is a plugin for Rollup, a popular module bundler used in JavaScript projects. This plugin is used to delete files and directories in your project as a part of the Rollup build process.
The plugin operates in a way that is consistent with the lifecycle hooks of Rollup, executing the deletion process before or after certain phases of your Rollup build. You can configure it based on your project requirements. It provides developers with the flexibility to control the point at which their specified files/folders should be deleted during the build process. It essentially contributes to maintaining the cleanliness of your build directory, thus preserving an optimal project structure.
The way it works is quite straightforward. The user specifies the lifecycle hook at which they want the deletion process to trigger along with the set of files or folders (targets) they want to delete. If the 'verbose' or 'dryRun' mode is enabled, the plugin will log the details of the deletion operation.
Key features of this plugin include:
- Ability to specify a custom rollup lifecycle hook on which the deletion operation should be performed.
- Support for 'runOnce', which stops the plugin from deleting the targets more than once for each Rollup run.
- Allows setting targets to be a list of files, folders, or patterns to delete.
- Option to print a detailed report of which files and folders were deleted (verbose mode).
- Ability to perform a dry run to see which files would be deleted without actually removing them.
In summary, @fnet/rollup-plugin-delete assists you in managing your project's file system more efficiently, by tailoring the deletion process according to your project's requirement, thus providing a cleaner and more concise environment.