I have one same form, where I pass data from 10 different components, including the ID of each table, I want to get from the DB the data by ID. The problem is that my code that asyncs the data is in 10 different .js controllers. For example, to get data of User from the DB, I should import /path/.../userController.js on the beginning of the script section. I parsed some string and got as result:
var path = /path/.../javascriptController
But, I get of course an error if I call on the top of the script section this:
import Controller from path;
Is it possible to import with any way .js files like:
import Controller from {{ path }}
How do I solve this problem?