Answer the question
In order to leave comments, you need to log in
Drupal 8, JS doesn't fire when displaying page and form URLs from a module at the same time?
The module creates a form, attaches JS to a specific URL.
If I create a page with the same URL, then the page is displayed and below it is my form from the block. But JS is no longer loaded.
How to fix JS connection?
Answer the question
In order to leave comments, you need to log in
At first I tried to add a library with styles and scripts to my plugin through the controller.
It didn't work if you create a page (material) in the admin panel using the same URL as the plugin.
I removed the controller, in the module, in the block declaration in build () I registered the addition of a library with styles. Everything worked
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question