marcusvy / live-bundle
Simple Live Reload for Symfony 8 + AssetMapper
Installs: 7
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Forks: 0
Type:symfony-bundle
pkg:composer/marcusvy/live-bundle
Requires
- php: >=8.4
- ext-ctype: *
- ext-iconv: *
- symfony/asset-mapper: 8.0.*
- symfony/console: 8.0.*
- symfony/dotenv: 8.0.*
- symfony/finder: 8.0.*
- symfony/flex: ^2
- symfony/framework-bundle: 8.0.*
- symfony/runtime: 8.0.*
- symfony/twig-bundle: 8.0.*
- symfony/ux-twig-component: *
- symfony/yaml: 8.0.*
Conflicts
This package is not auto-updated.
Last update: 2026-01-30 02:36:51 UTC
README
Installation
Use Composer to install the package:
composer require marcusvy/live-bundle --devAdd the <twig:LiveReload /> component to the Twig layout. Preferably before the closing tag .
<!DOCTYPE html>
<html>
<head></head>
<body>
<!-- Adicione o component Twig-->
<twig:LiveReload />
</body>
</html>
- Rode o comando
symfony console marcusvy:livereload:watch
Symfony CLI
For those using symfony-cli, you can create a .symfony.local.yaml file in the project root and work with workers. When you run the command symfony server:start, the service will run easily.
# .symfony.local.yaml
workers:
livereload:
cmd: ["symfony", "console", "marcusvy:livereload:watch"]
watch: ["config","src","templates","vendor"]
daemon: true
After creating the file, start the server embedded in symfony-cli
symfony server:start
Bundle Highlights
- Zero Node.js: Works in purely PHP environments.
- Turbo-Ready: Comes with Turbo Drive support (common in modern Symfony apps), performing a smooth reload instead of a hard refresh.
- Native AssetMapper: Uses the modern asset engine of Symfony 8, without needing npm install or build steps.
- Performance: Separates the scan process (Command) from the notification process (Controller), keeping the application fast.
- Free as Beer.
- Open Source: GPLv3