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

v1.0.7 2026-01-29 00:28 UTC

This package is not auto-updated.

Last update: 2026-01-30 02:36:51 UTC


README

Installation

  1. Use Composer to install the package:

    composer require marcusvy/live-bundle --dev
    
  2. Add 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>
  1. 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