尝试捆绑socket.io-client的早午餐问题
我很难将socket.io与早午餐/巴贝尔捆绑在一起 这是我的package.json:尝试捆绑socket.io-client的早午餐问题,socket.io,babeljs,brunch,Socket.io,Babeljs,Brunch,我很难将socket.io与早午餐/巴贝尔捆绑在一起 这是我的package.json: { [...] "dependencies": { "babel-runtime": "^5.8.0", "classnames": "2.2.3", "react": "^0.14.7", "react-dom": "^0.14.7", "react-redux": "^4.4.0", "redux": "^3.3.1", "socket.i
{
[...]
"dependencies": {
"babel-runtime": "^5.8.0",
"classnames": "2.2.3",
"react": "^0.14.7",
"react-dom": "^0.14.7",
"react-redux": "^4.4.0",
"redux": "^3.3.1",
"socket.io-client": "1.4.5"
},
"devDependencies": {
"babel-brunch": "^6.0.0",
"babel-cli": "^6.5.1",
"babel-eslint": "^5.0.0",
"babel-preset-es2015": "^6.5.0",
"babel-preset-react": "^6.5.0",
"babel-preset-stage-0": "^6.5.0",
"babel-register": "^6.5.2",
"brunch": "^2.4.2",
"css-brunch": "^2.0.0",
"eslint": "2.2.0",
"eslint-plugin-react": "4.1.0",
"fb-flo": "^0.5.0",
"fb-flo-brunch": "^1.7.22",
"javascript-brunch": "^2.0.0",
"rangen": "0.3.0",
"redux-devtools": "3.1.1",
"redux-devtools-dock-monitor": "1.1.0",
"redux-devtools-log-monitor": "1.0.4",
"sass-brunch": "2.0.0"
},
[...]
}
现在我的早午餐配置:
exports.config =
files:
javascripts:
joinTo:
'js/vendor.js': /^node_modules\//
'js/app.js': /^app\//
stylesheets:
joinTo:
'css/vendor.css': /^node_modules\//
'css/app.css': /^app\//
server:
run: yes
plugins:
babel:
presets: ['es2015', 'react', 'stage-0']
fbFlo:
enable: true
modules:
nameCleaner:
(path) ->
# remove app/js from all
newPath = path.replace(/^app\/js\//, '')
# if components or containers we remove component and the last file name
if newPath.match(/^components\//, '')
newPath = newPath.replace(/^components\/.*\//, '')
if newPath.match(/^containers\//, '')
newPath = newPath.replace(/^containers\//, '')
return newPath
autoRequire:
'js/app.js': ['app']
现在我的错误是:
Uncaught Error: Cannot find module "engine.io-parser/keys" from "engine.io-parser"
@ vendor.js:61
如果我将vendor.js中的“require('../keys.js')替换为“require('../lib/keys.js')”,这会起作用。。。
我的问题在哪里
谢谢你早午餐在这里。谢谢你的报告!一般来说,最好就我们的GitHub问题报告这些问题。你所经历的看起来确实是个问题,我已经提交了一份公关来解决这个早午餐的问题。谢谢你的报告!一般来说,最好就我们的GitHub问题报告这些问题。你所经历的看起来确实是个问题,我已经提交了一份公关来解决这个问题