@nx:js executors don't allow copying assets from gitignored folders #23293
b-smets
started this conversation in
Feature Requests
Replies: 1 comment 1 reply
-
no fix on this? |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Current Behavior
The @nx:js executors have an option to copy assets over to the build artifacts of the current project being built. However, this automatically ignores any files that match a pattern in the .gitignore / .nxignore files. Because of this, it is impossible to have a lib contribute assets to another lib / app if this assset is a build artifact.
In our setup we have a lib that produces a CSS file based on some SCSS input files. The CSS file is a build artifact.
We would like to consume this CSS file as an asset in another lib, using the assets of the @nx:js executor.
The culprits are the following lines:
https://github.com/nrwl/nx/blob/master/packages/js/src/utils/assets/copy-assets-handler.ts#L68
https://github.com/nrwl/nx/blob/master/packages/js/src/utils/assets/copy-assets-handler.ts#L185
Expected Behavior
I would expect this behaviour to be configurable. For example, an option could be added to the asset object to instruct NX to not ignore .gitignored files.
GitHub Repo
No response
Steps to Reproduce
Nx Report
Failure Logs
No response
Package Manager Version
No response
Operating System
Additional Information
No response
Beta Was this translation helpful? Give feedback.
All reactions