Javascript problems with image uri´s

Hello all,

i’ve a problem, I need to get a file through my js, but the script cant find the uri. I’ve tried different options and search the docs again, but id not found any solution…

...
template: 'user/themes/promedia/templates/vendors/socialfeed/facebook.html',
...

Is there something like a pre defined function like in twig: {{ url(theme://**) }} ?

@muuvmuuv I guess you want to set a path in your theme config and use it in the theme, right? I haven’t tested it, but {{ url(theme://**) }} should work.

I’m sorry i forgot to say that the js is in the theme/Promedia/js folder.
@Sommerregen No I want to get a file via JS. the above code is a twig thing and I dont know how I can get the same result for JS

You might already know it, but the path of the file you include must be relative to the js file path, not to the Grav root folder