Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

小哥,为什么require.async没有执行onload方法。。。 #14

Open
398218995 opened this issue Dec 21, 2014 · 6 comments
Open

小哥,为什么require.async没有执行onload方法。。。 #14

398218995 opened this issue Dec 21, 2014 · 6 comments

Comments

@398218995
Copy link

updateNeed方法 needNum-- 从来没减到过0 我用1.0.6兼容esl的也不行

@398218995
Copy link
Author

并且这个声明。。。。我的机器放到最后 他报错。。。
// FIS
esl_define = define;
esl_require = require;

@398218995
Copy link
Author

我确定引入了

<script type="text/javascript" src="http://s1.bdstatic.com/r/www/cache/ecom/esl/1-8-8/esl.min.js"></script>
<script type="text/javascript" src="/components/amd/esl.js"></script>

两个都引入了

最开始那个声明报错 我扔到最上面去了 然后onload的方法还是不执行

@hefangshi
Copy link
Member

你怎么又跑去用这个去了。。直接用mod.js就可以了,esl-mod.js也不是加载esl后使用的,直接使用就可以了

@398218995
Copy link
Author

。。我也是没办法啊 老是报错。。。

@hefangshi
Copy link
Member

没有那么多奇怪的用法。。。其实吧,你的jsp,只要把所有的include换成FIS的内嵌语法,再配合simple+autoload+mod.js就不会有问题了。

http://fis.baidu.com/docs/more/fis-standard-inline.html

不过区别就是原本widget嵌入是运行时嵌入的,FIS这里是构建时嵌入,那么一些根据条件加载的widget的静态资源并不会按照运行时的条件进行加载,而是一股脑的全部加载进来

@398218995
Copy link
Author

OK.好的 谢啦

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants