symfony/webpack-encore-bundle
Symfony bundle integrating Webpack Encore into your app. Adds asset building, versioning, and entrypoint management with simple Twig helpers for scripts/styles, plus sane defaults and easy configuration for modern JS/CSS workflows.
Full Changelog: https://github.com/symfony/webpack-encore-bundle/compare/v2.3.0...v2.4.0
Full Changelog: https://github.com/symfony/webpack-encore-bundle/compare/v2.2.0...v2.3.0
Hi Webpackers!
Almost a year later, here's a new release containing support for PHP 8.3 and 8.4, support remote entrypoints.json file, and the addition of the integrity attribute in the Link header for preloading.
Full Changelog: https://github.com/symfony/webpack-encore-bundle/compare/v2.1.1...v2.2.0
Happy packing!
Hi Webpackers!
A small bug fix to match return types in Symfony 7.
Full Changes: https://github.com/symfony/webpack-encore-bundle/compare/v2.1.0...v2.1.1
Have fun!
Hi Webpackers!
Full Changelog: https://github.com/symfony/webpack-encore-bundle/compare/v2.0.1...v2.1.0
Happy packing!
Hi Webpackers!
Diff: https://github.com/symfony/webpack-encore-bundle/compare/v1.17.1...v1.17.2
Happy packing!
Hi Webpackers!
This release is relaxes the version requirements for symfony/service-contracts to allow upgrading on 5.4 projects - see #214
Diff: https://github.com/symfony/webpack-encore-bundle/compare/v2.0.0...v2.0.1
Happy packing!
Hi Webpackers!
A quick fix for version 1.17.0 that fixes this error when used with StimulusBundle:
The service "twig" has a dependency on a non-existent service "webpack_encore.twig_stimulus_extension". Did you mean this: "webpack_encore.twig_entry_files_extension"
Upgrading should resolve the error. See #213.
Diff: https://github.com/symfony/webpack-encore-bundle/compare/v1.17.0...v1.17.1
Happy packing!
Hi Webpackers!
This release is identical to 1.17.0 except that it removes deprecated code.
Version 2.0 also requires PHP 8.1 or higher and Symfony 5.4 or higher.
If you're using symfony/flex, when you upgrade your symfony/webpack-encore-bundle recipe to the 2.0 version, it may try to remove certain files like assets/controllers.json or assets/bootstrap.js. You should ignore these changes and restore the files. This happens because these files moved from the recipe for symfony/webpack-encore-bundle to symfony/stimulus-bundle. To the update system, it looks like the files are being removed.
Diff: https://github.com/symfony/webpack-encore-bundle/compare/v1.17.0...v2.0.0
Happy packing!
Hi Webpackers!
This release deprecates the stimulus_controller(), stimulus_action() and stimulus_target functions because they are now included with the new symfony/stimulus-bundle. Run composer require symfony/stimulus-bundle to grab the functions from that package instead.
Diff: https://github.com/symfony/webpack-encore-bundle/compare/v1.16.1...v1.17.0
Happy packing!
Hi Webpackers!
This release fixes a bug if using the stimulus_* functions most commonly with the form system - see https://github.com/symfony/webpack-encore-bundle/pull/178#issuecomment-1379604029
Diff: https://github.com/symfony/webpack-encore-bundle/compare/v1.16.0...v1.16.1
Happy packing!
Hi Webpackers!
This release adds support for Stimulus CSS Classes - https://stimulus.hotwired.dev/reference/css-classes.
Diff: https://github.com/symfony/webpack-encore-bundle/compare/v1.15.1...v1.16.0
Happy packing!
Hi Webpackers!
This release follows up on the new superpowers of stimulus_controller(), stimulus_action() and stimulus_target() from 1.15.0 with some internal changes regarding how the code is deprecated and documented
Diff: https://github.com/symfony/webpack-encore-bundle/compare/v1.15.0...v1.15.1
Happy packing!
Hi Webpackers!
This release makes stimulus_controller(), stimulus_action() and stimulus_target() much more user-friendly when you either (A) need to add multiple controllers/actions/targets or if you want to pass a controller/action/target into Symfony's form system. For example:
{{ form_row(form.password, {
attr: stimulus_action('hello-controller', 'checkPasswordStrength').toArray()
}) }}
How cool is that?
Diff: https://github.com/symfony/webpack-encore-bundle/compare/v1.14.1...v1.15.0
Happy packing!
Hi Webpackers!
This release contains an important bug fix for a bug that was introduced in 1.14.0 if you use sub-requests (e.g. {{ render(controller(...)) }} or similar). If you have any continued problems, let us know. See #166.
May 3rd, 2022
Diff: https://github.com/symfony/webpack-encore-bundle/compare/v1.14.0...v1.14.1
Happy packing!
Hi Webpackers!
This release contains one small feature and one big fix, which affects how encore assets are handled during sub-requests.
February 14th, 2022
Diff: https://github.com/symfony/webpack-encore-bundle/compare/v1.13.2...v1.14.0
Happy packing!
Hi Webpackers!
This release contains just one fix to help install when using Symfony 6.
December 2nd, 2021
Diff: https://github.com/symfony/webpack-encore-bundle/compare/v1.13.1...v1.13.2
Happy packing!
Hi Webpackers!
This release contains a fix for stimulus_controller when passing null to one of the values.
November 28th, 2021
Diff: https://github.com/symfony/webpack-encore-bundle/compare/v1.13.0...v1.13.1
Happy packing!
Hi Webpackers!
This release contains support for Symfony 6 + 1 bug fix!
November 19th, 2021
Diff: https://github.com/symfony/webpack-encore-bundle/compare/v1.12.0...v1.13.0
Happy packing!
Hi Webpackers!
This release contains 2 new functions to help when working with Stimulus.
Diff: https://github.com/symfony/webpack-encore-bundle/compare/v1.11.2...v1.12.0
Happy packing!
Hi Webpackers!
This release contains a bug fix for when using stimulus_controller with a boolean "value" and cleans up some deprecations:
Diff: https://github.com/symfony/webpack-encore-bundle/compare/v1.11.1...v1.11.2
Happy packing!
Hi Webpackers!
This release contains a bug fix for the script_attributes and link_attributes feature introduced in v1.9.0.
Previously, you could not disable an attribute by setting it to false - for example:
webpack_encore:
script_attributes:
defer: false
Before this release, this would add a defer="" attribute. Now it correctly will not include the attribute.
Setting an attribute to null - defer: null - WILL include the attribute.
See #113 for more details.
Also see #112 where the new stimulus_controller() function's "safety" was limited to HTML attributes thanks to @stof.
Diff: https://github.com/symfony/webpack-encore-bundle/compare/v1.11.0...v1.11.1
Happy packing!
Hi Webpackers!
A short time ago, v1.10.0 was released with a new stimulus_controller() Twig function. This release makes it simpler to use that with only 1 controller:
<!-- new syntax -->
{{ stimulus_controller('chart', { 'name': 'Likes', 'data': [1, 2, 3, 4] }) }}
<!-- existing, longer syntax (still works) -->
{{ stimulus_controller({ 'chart': { 'name': 'Likes', 'data': [1, 2, 3, 4] } }) }}
See #110 for more details.
Diff: https://github.com/symfony/webpack-encore-bundle/compare/v1.10.0...v1.11.0
Happy packing!
Hi Webpackers!
If you've been following the Symfony UX initiative, then this release is for you!
stimulus_controller() Twig function to help render Stimulus controllers - #109 thanks to @tgalopinDiff: https://github.com/symfony/webpack-encore-bundle/compare/v1.9.0...v1.10.0
Happy packing!
Hi Webpackers!
This release contains a long-asked-for feature: the ability to control the attributes on the script and link tags generated by this bundle. There are 3 ways to control them: (A) globally via config, (B) when using the Twig functions or (C) via an event listener. See the docs for more details: https://github.com/symfony/webpack-encore-bundle#custom-attributes-on-script-and-link-tags
Diff: https://github.com/symfony/webpack-encore-bundle/compare/v1.8.0...v1.9.0
Happy packing!
Hi friends!
This release adds support for PHP 8! See #98 for details. And a big thanks to @jmsche for their work on that PR.
Happy packing!
Hi friends!
This release contains a single bug fix for a tricky issue: you render a Twig template (which uses the encore_entry_link_tags() and encore_entry_script_tags() functions) and then an exception (for some reason) is thrown, Symfony would correctly render your error template BUT any calls to encore_entry_link_tags() in that template would render no link/script tags because they were "already rendered". This is due to an important feature in WebpackEncoreBundle where any link or script tag is never rendered multiple times... to avoid having the same JS or CSS file rendered on the same page multiple times.
However, in the case of an exception that's thrown in Twig, WebpackEncoreBundle would think that a JS or CSS file had been rendered, but in reality, the HTML it was rendered into was never used - because the exception caused that HTML to not be used and for the "error" page to be used instead.
This was fixed in #74 thanks to @tbmatuka and @ckrack by adding an exception listener that "resets" this bundle's "memory" of what it has rendered.
If you experience any adverse effects, please open an issue :).
Happy packing!
Hi Webpackers!
This fixes a compatibility issue with Symfony 4.4 & 5.0 when using the preload: true option. See #84.
Happy packing!
Hi friends!
Symfony 5 won't be out until the end of November, but this bundle is now ready for it!
Happy packing!
A tiny release, but one that fixes an annoying bug with the composer autoloader.
#65 - [Contracts] Update dependency to use symfony/service-contracts - thanks to @wbrinkman
Happy Webpacking!
How can I help you explore Laravel packages today?