CVarisco / create-component-app

Tool to generate different types of React components from the terminal. 💻
MIT License
859 stars 58 forks source link

Does not process files in template subdirectories #36

Closed mosanger closed 7 years ago

mosanger commented 7 years ago

This is a great little tool and I'd love to use it... Our current setup dictates test files in a subfolder called __test__

So the tree is as follows:

template
│   index.js
│   COMPONENT_NAME.jsx  
│   SubComponent.jsx
│  
└───__test__
│   │   COMPONENT_NAME.spec.jsx
│   │   SubComponent.spec.jsx
│   
└───__stories__
    │   COMPONENT_NAME.stories.jsx

If I create a template like this the follwing error occurs:

(node:672) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Error: EISDIR: illegal operation on a directory, read (node:672) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code. index.js

Also, the path option in the config file seems to have no effect when using templates, as it resets to ./src/components when run.

CVarisco commented 7 years ago

Hi @mosanger !

thanks a lot for your support 🙂 I'll investigate better on what doesn't work.

If you want contribute feel free to help me 🙂 Thanks