Cannot install converseJS properly in Laravel 5 -
i working on application trying chat feature working using conversejs xmpp client on front end , openfire rtc on end.
i working laravel 5 on end, , being naive developer am, placed files in public folder , linked js , css file webpage.
<link rel="stylesheet" type="text/css" media="screen" href="/converse/css/converse.min.css"> <script src="/converse/builds/converse.min.js"></script>
it working in firefox , can see chat pluigin in chrome. error see in console is:
uncaught error: see almond readme: incorrect module build, no module name
i not sure causing this. placing files in public folder , linking pages, right way? or have in laravel 5 running?
you receive error because conversejs uses almond amd loader , cannot handle modules without name.
for example trow error mentioned:
$(function(){ ... });
so should use instead:
jquery(function($){ ... });
more info here
try put conversejs script last , wrap code jquery plugins mentioned before.
Comments
Post a Comment