-
-
Notifications
You must be signed in to change notification settings - Fork 5.1k
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
Adding docs around the new "css" Encore functions and disabling file tracking #13652
Conversation
c754f00
to
1990989
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.
Do we need a versionadded directive?
{{ encore_entry_js_source('my_entry')|raw }} | ||
</script> | ||
|
||
If you can't use these `encore_entry_*_source` functions, you can instead |
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.
Double backticks please
@@ -69,6 +69,7 @@ Guides | |||
|
|||
* :doc:`Using Bootstrap CSS & JS </frontend/encore/bootstrap>` | |||
* :doc:`Creating Page-Specific CSS/JS </frontend/encore/page-specific-assets>` | |||
* :doc:`Rendering Multiple Templates in a Request: Emails, PDFs </frontend/encore/file-tracking>` |
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.
Why aren't we doing :doc:`/frontend/encore/file-tracking`
here? :)
{{ encore_entry_script_tags('entry1') }} | ||
{% do encore_enable_file_tracking() %} | ||
|
||
With this, *all* JS and CSS files for `entry1` will be rendered and |
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.
With this, *all* JS and CSS files for `entry1` will be rendered and | |
With this, *all* JS and CSS files for ``entry1`` will be rendered and |
bundle re-renders CSS or JS files that it previously rendered. For | ||
example, in a controller:: | ||
|
||
|
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.
|
||
|
||
// src/Controller/SomeController.php | ||
|
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.
namespace App\Controller; | |
public function index(EntrypointLookupInterface $entrypointLookup) | ||
{ | ||
$entrypointLookup->reset(); | ||
// render a template |
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.
// render a template | |
// ... render a template |
// render a template | ||
|
||
$entrypointLookup->reset(); | ||
// render another template |
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.
// render another template | |
// ... render another template |
Let's close this old pending PR because we're moving away from Webpack Encore very fast so it doesn't make sense to try to add new complex features like this one. Thanks! |
Hi!
Docs for symfony/webpack-encore-bundle#91
Cheers!