LaravelPackages.net
Acme Inc.
Toggle sidebar
cpiber/puller

A laravel package for broadcasting events using long-polling

4
0
v1.1
About cpiber/puller

cpiber/puller is a Laravel package for a laravel package for broadcasting events using long-polling. It currently has 0 GitHub stars and 4 downloads on Packagist (latest version v1.1). Install it with composer require cpiber/puller. Discover more Laravel packages by cpiber or browse all Laravel packages to compare alternatives.

Last updated

Puller

A laravel package for broadcasting events using long-polling

Installation

php artisan install:broadcasting  # do not install reverb, puller will be used instead
composer require as247/puller
php artisan migrate
npm i puller-js

Usage

1. Update broadcasting driver in .env file

BROADCAST_DRIVER=puller

2. Configure Echo

import Echo from 'laravel-echo'
import Puller from 'puller-js'
window.Echo = new Echo({
    broadcaster: Puller.echoConnect,
});

Troubleshooting

  • If Laravel does not pick up the puller driver, add it to your bootstrap/providers.php:

    <?php
    
    return [
        App\Providers\AppServiceProvider::class,
        // ... your other service providers ...
        As247\Puller\PullerServiceProvider::class,
    ];
    
  • To publish the puller configuration as well as database migrations, run this command: php artisan vendor:publish --provider "As247\Puller\PullerServiceProvider"

Star History Chart