laravel-theme
laravel-theme copied to clipboard
how can i create my custom-js on views ?
Normally ,
i can create
@yield('custom-js')
on master blade and use it in my views like
@section('custom-js')
and i can write my custom-js codes on views
So how can i do it with laravel-theme ? i couldnt get the idea... Any example ?
Please read in https://github.com/teepluss/laravel-theme#basic-usage-of-assets.
Scroll down and find "Writing in-line style or script".
I have the same issue. I need to send section('js) to layout @yield('js') to use jsvalidation, like this:
@section('js')
<script type="text/javascript" src="{{ asset('vendor/jsvalidation/js/jsvalidation.js')}}"></script>
{!! JsValidator::formRequest('App\Http\Requests\CreateAccount') !!}
@endsection