jquery 无法加载

53 views
Skip to first unread message

张全华

unread,
Feb 27, 2013, 10:49:43 AM2/27/13
to se...@googlegroups.com
我安装 seajs 的例子 自己准备实践一下 一开始就遇到困难了! jquery无法加载! 文件请看附件!麻烦 指点一下 什么问题!
test.rar

Frank Wang

unread,
Feb 27, 2013, 8:21:49 PM2/27/13
to seajs
sea.js 没下载全呀,到这里下载:


将 dist 目录下的 plugin-shim 等文件放在 sea.js 同级目录。


On Wed, Feb 27, 2013 at 11:49 PM, 张全华 <huaz...@gmail.com> wrote:
我安装 seajs 的例子 自己准备实践一下 一开始就遇到困难了! jquery无法加载! 文件请看附件!麻烦 指点一下 什么问题!

--
You received this message because you are subscribed to the Google Groups "seajs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to seajs+un...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 



--
王保平 / 玉伯(射雕)
送人玫瑰手有余香

张全华

unread,
Feb 28, 2013, 2:18:18 AM2/28/13
to se...@googlegroups.com
O(∩_∩)O哈哈~  谢谢了指点!终于可以了!

2013/2/28 Frank Wang <lifes...@gmail.com>

--
You received this message because you are subscribed to a topic in the Google Groups "seajs" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/seajs/O6uC1k_WJfs/unsubscribe?hl=en.
To unsubscribe from this group and all its topics, send an email to seajs+un...@googlegroups.com.

轻扬

unread,
Mar 1, 2013, 12:11:49 PM3/1/13
to se...@googlegroups.com
您好:
    借这个帖子问一下吧,昨晚看了好久关于模块标识这一节的内容
    始终无法弄清楚路径的问题
    现在只明白怎么正确引用seajs文件,但是其他就搞不懂了
    1.在script标签中的data-config和data-main是相对于谁的
    2.在config.js里的alias里的js文件路径是相对于谁的
    3.plugin-shim插件又是相对于谁的
    4.模块之间貌似只相对于引用模块的,不知道对不对

我做了好几次试验,只有按照官网实例的目录做才没有错误,一旦我自行改变js目录,就搞不清楚谁该相对谁了,求解答。。。。

在 2013年2月28日星期四UTC+8上午9时21分49秒,Frank Wang写道:

Frank Wang

unread,
Mar 5, 2013, 1:50:15 AM3/5/13
to seajs
查看这里的例子:


如果目前结构有修改,将修改后的目录,以及你的 config 贴出来
不然没法讨论,呵呵




2013/3/2 轻扬 <chsh...@gmail.com>

vfasky

unread,
Mar 5, 2013, 1:52:58 AM3/5/13
to se...@googlegroups.com
借问一下, 用 shim 插件加载 Raphael , 会报 eve 没有定义. 请问怎么解决?

Frank Wang

unread,
Mar 5, 2013, 1:56:06 AM3/5/13
to seajs
 Raphael 依赖全局的一个 eve

建议用 shim 加载时,依旧保留全局变量


2013/3/5 vfasky <vfa...@gmail.com>

vfasky

unread,
Mar 5, 2013, 1:57:12 AM3/5/13
to se...@googlegroups.com
如何保留全局变量? 有文档吗?

Frank Wang

unread,
Mar 5, 2013, 2:14:40 AM3/5/13
to seajs
说说你是怎么配置 shim 的。默认应该就会保留全局变量。


2013/3/5 vfasky <vfa...@gmail.com>

vfasky

unread,
Mar 5, 2013, 2:16:42 AM3/5/13
to se...@googlegroups.com
这是我完整的配置

seajs.config({
  // Set aliases for common libraries
  alias: {
    'jquery': 'common/jquery-1.9.1.min.js',
    'raphael': 'common/raphael-2.1.0.min.js'
  },

  // Add plugins
  plugins: ['shim'],

  // Configure shim for non-CMD modules
  shim: {
    'jquery': {
      exports: 'jQuery'
    },
    'jquery-plugins': {
      match: /jquery\.[a-z].*\.js/,
      deps: ['jquery']
    },
    'raphael': {
      exports: 'Raphael',
      deps: ['jquery']
    },
  }
});

Frank Wang

unread,
Mar 5, 2013, 3:36:00 AM3/5/13
to seajs


2013/3/5 vfasky <vfa...@gmail.com>

vfasky

unread,
Mar 6, 2013, 9:51:39 PM3/6/13
to se...@googlegroups.com
seajs 2.0.0b3 是否不支持IE9 以下浏览器?

Frank Wang

unread,
Mar 6, 2013, 9:55:19 PM3/6/13
to seajs
支持呀。可以看 demo: http://seajs.github.com/examples/hello.html

记得清空浏览器缓存,我估计是缓存问题。


2013/3/7 vfasky <vfa...@gmail.com>
PastedGraphic-1.tiff

vfasky

unread,
Mar 6, 2013, 10:06:56 PM3/6/13
to se...@googlegroups.com
我这里有个demo, scroll.html 只是简单的调用类. 在 ie9 以下浏览器就没法运行了
projectG.zip

Frank Wang

unread,
Mar 6, 2013, 11:27:00 PM3/6/13
to seajs
更新到 seajs 2.0.0b3 哦


2013/3/7 vfasky <vfa...@gmail.com>
我这里有个demo, scroll.html 只是简单的调用类. 在 ie9 以下浏览器就没法运行了

--
You received this message because you are subscribed to the Google Groups "seajs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to seajs+un...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




在 2013-3-7,上午10:55,Frank Wang <lifes...@gmail.com> 写道:

http://seajs.github.com/examples/hello.html


Reply all
Reply to author
Forward
0 new messages