We are in process of splitting our large ember app into logical chunks and delay load few of the modules to improve performance.
We have an entry which in turn recursively includes all dependencies and creates one big rjs optimized file during build process. We want to load few core components and the routes during initial load and delay load everything else.
We want to nest our require calls inside route and use beforeModelHook to load dependent controllers, templates, components as specified in this guide http://ift.tt/1SpjR9Z
Now the problem is if we skip import statement
import mycontroller = require("mycontroller")
and use nested require
beforeModel() {
require(["mycontroller"])
...
}
typescript fails to list mycontroller as dependency when compiled. How to resolve this issue?
What are other ways of achieving improving performance?
Aucun commentaire:
Enregistrer un commentaire