Skip to content
This repository has been archived by the owner on Jun 4, 2020. It is now read-only.

offer to fix the path in the file name #25

Open
pmelieshchenko opened this issue Oct 17, 2019 · 0 comments
Open

offer to fix the path in the file name #25

pmelieshchenko opened this issue Oct 17, 2019 · 0 comments

Comments

@pmelieshchenko
Copy link

pmelieshchenko commented Oct 17, 2019

TemplateGenerator.js

add something like this:

...
key: '_createDirectory',
value: function _createDirectory(dirPath, data, fileTypes) {
...
name = name.split('/').slice(-1).join('').split('\'').slice(-1).join('');

so that you can generate a component with a path from the root of the project
like this:
vgc src/components/Home

this is probably not the best solution, but I really want to be able to generate components from the root of the project

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant