🐛 Bug Report
The generated index.tsx exports file from the below command appears to be either incomplete or truncated. I get a different set of exports written to file each time I run the command. It looks like there is some kind of race condition going on.
To Reproduce
Steps to reproduce the behavior:
-
Create multiple directories of SVG icons.
-
Run the following:
rm -rf src/icons; svgr --ext tsx -d src/icons src/assets/**/
- Note the generated exports in
src/icons/index.tsx
Expected behavior
Exports for all of the generated React components are included within the index.tsx file.
Link to repl or repo (highly encouraged)
Repro can be found here on this branch:
https://github.com/Royal-Navy/standards-toolkit/tree/repro/svgr-generated-exports-truncated/packages/icon-library
Env info
## System:
- OS: macOS 10.15.3
- CPU: (8) x64 Intel(R) Core(TM) i7-6700HQ CPU @ 2.60GHz
- Memory: 90.29 MB / 16.00 GB
- Shell: 5.7.1 - /bin/zsh
## Binaries:
- Node: 12.13.0 - ~/.nvm/versions/node/v12.13.0/bin/node
- Yarn: 1.19.1 - ~/.yarn/bin/yarn
- npm: 6.12.0 - ~/.nvm/versions/node/v12.13.0/bin/npm
🐛 Bug Report
The generated
index.tsxexports file from the below command appears to be either incomplete or truncated. I get a different set of exports written to file each time I run the command. It looks like there is some kind of race condition going on.To Reproduce
Steps to reproduce the behavior:
Create multiple directories of SVG icons.
Run the following:
src/icons/index.tsxExpected behavior
Exports for all of the generated React components are included within the
index.tsxfile.Link to repl or repo (highly encouraged)
Repro can be found here on this branch:
https://github.com/Royal-Navy/standards-toolkit/tree/repro/svgr-generated-exports-truncated/packages/icon-library
Env info