All Questions
Tagged with page-controller javascript
2 questions
0
votes
0
answers
278
views
How can I add inline JavaScript on a page returned from a custom controller (not with a library)?
How can I add another render element that contains my custom JavaScript code?
Do I use ['#attached']['html_head'] or code similar to the following one?
$build['body']['script'] = [
'#type' => '...
1
vote
1
answer
2k
views
Add JavaScript inside controller
How to add JavaScript inside controller? I don't want to call build form. I can call css or js in src/Form/Form.php but I want to call css or js inside Controller src/Controller/Controller.php
This ...