-
-
Notifications
You must be signed in to change notification settings - Fork 496
[Webpack Encore] Change default assets directory structure #789
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request passes validation.
In addition to Another question: you have experience in JS world ... do they use |
Yes, this is my proposal indeed: nowadays, in most front-end applications the Javascript is the most important bit of code running on the client. Having JS entrypoints at the root directory and then letting people have their imported scripts inside directories under assets reduce the length of paths, avoid relying on a format and increase discoverability.
That's a good point. I had a quick look:
I used sylesheet as a reference to the |
d1020b5
to
c8fd966
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request passes validation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request passes validation.
Let's ping some people who know Webpack Encore very well in case they find some problem with this: @weaverryan @Lyrkan @Kocal @stof Thanks! |
Hi, and thanks for your proposal! This seems very legit to me. For my own case, on my projects and company projects, I always use a structure like this:
We also use I don't think I ever used the actual A big +1 for me! |
@tgalopin would you be able to make a docs PR? This will break some paths - we need to get those updated before merging this. But other than that, I think it's a great idea! |
c8fd966
to
efb79cb
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request passes validation.
efb79cb
to
910cccb
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request passes validation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request passes validation.
I updated the PR and added documentation. This should be ready :) . |
…ture (tgalopin) This PR was submitted for the master branch but it was merged into the 5.1 branch instead. Discussion ---------- [Webpack Encore] Change default assets directory structure Adapt the documentation for symfony/recipes#789 Commits ------- e5aa761 [Webpack Encore] Change default assets directory structure
I propose to update the default
assets
directory structure present in the Webpack Encore recipe.The reasoning behind this is the following: