New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Prettier runs too late and causes conflicts during re-generation #7172
Comments
I was also thinking about doing that and I guess it should be possible using the yeoman pipe feature. I'll look into this later |
I have something starting to work by using yeoman |
Nice work. I assume it would be easy to pass our settings. I didn't look at
the code yet, but assume you will be using gulp filters
…On Fri, 9 Mar 2018, 2:58 am Gaël Marziou, ***@***.***> wrote:
I have something starting to work by using yeoman
registerTranformStream(), for now it only uses default settings, I must
pass it our configuration
***@***.***
<gmarziou@b88051b>
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#7172 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ABDlF2qzUgoJKpSFuetPbSV-poNNqsfwks5tceGqgaJpZM4SSTn0>
.
|
Yes I used gulp-filter, I also used gulp-prettier but I had to modify its code a little so finally I rewrote it as a short inner function |
@deepu105 there's a bootstrap issue here: I don't know what I could do with yeoman's in-memory filesystem. A simple approach could be to define our |
I could not find a way to specify a configuration file path through API so I may do the reverse: defining options in a variable and generating the |
Can you create a PR with what you hv so far, ill work on it tomorrow. I'll
find a way
…On Fri, 9 Mar 2018, 7:22 pm Gaël Marziou, ***@***.***> wrote:
I could not find a way to specify a configuration file path through API so
I may do the reverse: define options in a variable and generate the
.prettierrc file from it.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#7172 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ABDlFxJZyZMRLd0jT7aofykvCtCsg-m8ks5tcshcgaJpZM4SSTn0>
.
|
Here it is, I added it only to app generator. |
Currently, prettier runs after code generation.
Due to this, when re-generating an entity or an app, yeoman shows many conflicts (~25% of generated files) only due to reformatting that runs later.
I don't know enough yeoman to say whether it is easy to run prettier after template rendering and before yeoman compares file contents.
The text was updated successfully, but these errors were encountered: