In my current legacy app, I group together certain set of dependencies and define a common mod.js (which can then be referenced by any module requiring this set)
dojo.provide("app.common.mod");
dojo.require("app.common.Constant");
dojo.require("app.common.GlobalData");
dojo.require("app.common.SomeUIPanel");
Now moving to an Ember app, I'll have to follow an MVC structure.
So my question is, in Ember, is there any way by which I can list/group these dependencies together and refer from anywhere. i.e. use
import 'commonMod' from commonMod;
Also not sure if it is not necessarily required in Ember. I mean does Ember have access to any object A from any other object B (i.e. whether it is a model/controller/route, etc)
Aucun commentaire:
Enregistrer un commentaire