symfony/webpack-encore-bundle
's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.Name | Version | Size | License | Type | Vulnerabilities |
---|---|---|---|---|---|
symfony/asset | v7.0.7 | - | MIT | prod | |
symfony/config | v7.0.7 | - | MIT | prod dev | |
symfony/dependency-injection | v7.0.7 | - | MIT | prod dev | |
symfony/http-kernel | v7.0.7 | - | MIT | prod dev | |
symfony/service-contracts | v3.5.0 | - | MIT | prod dev |
The symfony/webpack-encore-bundle is a tool designed to boost the performance and efficiency of your Symfony applications. It integrates your Symfony application with Webpack Encore which is a simpler way to manage your JavaScript and CSS assets. One of the main features of this bundle is its ability to use the splitEntryChunks()
function from Webpack Encore, which allows for the separation of your application's JavaScript and CSS codes into smaller, more manageable chunks. By reading an entrypoints.json
file, it helps render all the needed dynamic script
and link
tags, improving the performance of your web application.
To use the symfony/webpack-encore-bundle in your Symfony application, you first need to install it. This typically involves using composer, the PHP package manager. Below is an example of how you would include it in your project:
composer require symfony/webpack-encore-bundle
Once the package is installed, your Symfony application can start benefiting from the features provided by the bundle. The bundle will automatically read from the entrypoints.json
file generated by Webpack Encore and render the correct script
and link
tags in your templates.
The use of splitEntryChunks()
is especially helpful in large applications where you have a lot of JavaScript or CSS codes. This method allows you to split your code into smaller, more manageable chunks, which can then be loaded independently. This can improve loading times and overall performance.
The symfony/webpack-encore-bundle documentation is located on the Symfony website. It provides a comprehensive guide on how to install, configure, and effectively use the bundle in your Symfony applications. You can access it at the following link: symfony/webpack-encore-bundle documentation