To receive broadcast notifications in laravel 5.3 , I needed to include laravel-echo and pusher-js files in my click templates.
I know this is possible with the npm package manager , as described in laravel docs as follows:
npm install
And then in the resouces/assets/js/app.js import it like this:
import Echo from "laravel-echo" window.Echo = new Echo({ broadcaster: 'pusher', key: 'your-pusher-key-here' });
But I have a simple js file in which all my scripts are inside, and I did not use npm in my project, and all my javascript files were .js .
I went to the laravel-echo github , but I did not find a js-formatted file that I can use on my pages.
Is there a way besides npm to enable laravel-echo?
Update:
I found that the above codes are based on Typescript . I am not familiar with Typescript. only i know that it can compile clean javascript files. I am looking for laravel-echo as a js file that could include it on my page and use the included functions and methods. is this an offering?
ABDeveloper
source share