Closed rarkins closed 8 years ago
Interesting, thanks for pointing it out! I'm curious to hear how other folks feel about adding a .path()
method. In general I've tried to keep the loadjs
feature set down to the bare essentials.
HTTP2 will mean that bundling becomes an antipattern. Therefore I have 20+ separate libraries/files I need to load async, so adding .path()
makes the code a lot simpler.
IMHO it adds more state to loadjs making it more implicit what actually is loaded. I would always prefer managing the basePath in the application and prefix it explicitly.
I agree with @Niondir - even if .path()
was available I would still prefer to manage the basePath in the application to make it explicit.
I'm going to close this issue for now. If some folks still want .path()
I'm happy to re-open the discussion so we can get more opinions.
This is something I use in
$script.js
which seems to be missing inloadjs
. e.g. would be used like: