Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

$ is not define in laravel

We must delete "defer attribute"

->app.blade.php

   //this is wrong
   <script src="{{ asset('js/app.js') }}" defer></script>
   
   //this is correct
   <script src="{{ asset('js/app.js') }}" ></script>
 
 ->resources>js>app.js
 	window.$ = require("jquery")
 	window.bootstrap = require("bootstrap");

   
 
PREVIOUS NEXT
Tagged: #define #laravel
ADD COMMENT
Topic
Name
7+7 =