{"action":"closed","issue":{"url":"https://api.github.com/repos/umijs/umi/issues/614","repository_url":"https://api.github.com/repos/umijs/umi","labels_url":"https://api.github.com/repos/umijs/umi/issues/614/labels{/name}","comments_url":"https://api.github.com/repos/umijs/umi/issues/614/comments","events_url":"https://api.github.com/repos/umijs/umi/issues/614/events","html_url":"https://github.com/umijs/umi/issues/614","id":331067760,"node_id":"MDU6SXNzdWUzMzEwNjc3NjA=","number":614,"title":"关于model动态加载的问题","user":{"login":"yoyooyooo","id":18062745,"node_id":"MDQ6VXNlcjE4MDYyNzQ1","avatar_url":"https://avatars1.githubusercontent.com/u/18062745?v=4","gravatar_id":"","url":"https://api.github.com/users/yoyooyooo","html_url":"https://github.com/yoyooyooo","followers_url":"https://api.github.com/users/yoyooyooo/followers","following_url":"https://api.github.com/users/yoyooyooo/following{/other_user}","gists_url":"https://api.github.com/users/yoyooyooo/gists{/gist_id}","starred_url":"https://api.github.com/users/yoyooyooo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yoyooyooo/subscriptions","organizations_url":"https://api.github.com/users/yoyooyooo/orgs","repos_url":"https://api.github.com/users/yoyooyooo/repos","events_url":"https://api.github.com/users/yoyooyooo/events{/privacy}","received_events_url":"https://api.github.com/users/yoyooyooo/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-06-11T07:06:12Z","updated_at":"2018-06-11T07:18:24Z","closed_at":"2018-06-11T07:18:24Z","author_association":"NONE","body":"如果我有a，b 两个页面，分别对应2个model，a页面用到了b页面的组件，也用到了b的model。\r\n如果我进首页后直接进a页面，这时候a页面，这时候b的model还没加载，就出错了。\r\n\r\n请问我是应该把b页面里a用到的相关代码都挪到global上吗，但是这样感觉不太好，，这些代码是b页面带的，放b的model比较直观。。\r\n我的项目结构是这样的：\r\n```\r\n+ pages\r\n    + a\r\n        + components\r\n        - index.js\r\n        - model.js\r\n    + b\r\n        + components\r\n        - index.js\r\n        - model.js\r\n```\r\n还是有更合理的解决方法吗？ "}}
{"actor":{"display_login":"sorrycc"}}