【发布时间】:2016-02-29 17:32:42
【问题描述】:
我完全不知道如何插入单独的基础 javascript。它似乎总是破坏我的代码。例如我需要使用下拉菜单js。在它声明的文档中
正在初始化 文件foundation.dropdownMenu.js 必须包含在你的JavaScript 中才能使用这个插件,
连同foundation.core.js。
此插件还需要这些实用程序库:
foundation.util.keyboard.js
foundation.util.box.js
foundation.util.nest.js
这看起来很简单,所以我按此顺序执行了以下操作
bower_components/foundation-sites/js/foundation.core.js //check
bower_components/foundation-sites/js/foundation.util.mediaQuery.js
bower_components/foundation-sites/js/foundation.util.timerAndImageLoader.js
bower_components/foundation-sites/js/foundation.util.keyboard.js //check
bower_components/foundation-sites/js/foundation.util.box.js //check
bower_components/foundation-sites/js/foundation.util.nest.js //check
bower_components/foundation-sites/js/foundation.dropdown.js
bower_components/foundation-sites/js/foundation.dropdownMenu.js //check
bower_components/foundation-sites/js/foundation.equalizer.js
我遵循对我来说核心 1st 比 util 比插件更合乎逻辑的东西
但它告诉我foundation.util.nest.js:6 Uncaught SyntaxError: Unexpected token =
如果我把所有foundation.min.js文件都放了,错误就消失了,所以我知道它一定是缺少依赖或者顺序不正确
是否有任何资源可以明确说明基础 js 的依赖关系?相反,每次我必须跟踪和错误它。
【问题讨论】:
标签: javascript zurb-foundation zurb-foundation-6