File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change 2222{{-- CUSTOM CSS --}}
2323@push('crud_fields_styles')
2424 {{-- How to load a CSS file? --}}
25- @loadOnce(asset( 'dummyFieldStyle.css') )
25+ @loadOnce('dummyFieldStyle.css')
2626
2727 {{-- How to add some CSS? --}}
2828 @loadOnce('dummy_field_style')
3737{{-- CUSTOM JS --}}
3838@push('crud_fields_scripts')
3939 {{-- How to load a JS file? --}}
40- @loadOnce(asset( 'dummyFieldScript.js') )
40+ @loadOnce('dummyFieldScript.js')
4141
4242 {{-- How to add some JS to the field? --}}
4343 @loadOnce('bpFieldInitDummyFieldElement')
44+ <script>
4445 function bpFieldInitDummyFieldElement(element) {
4546 // this function will be called on pageload, because it's
4647 // present as data-init-function in the HTML above; the
4748 // element parameter here will be the jQuery wrapped
4849 // element where init function was defined
4950 console.log(element.val());
5051 }
52+ </script>
5153 @endLoadOnce
5254@endpush
You can’t perform that action at this time.
0 commit comments