o2team / elf Goto Github PK
View Code? Open in Web Editor NEW灵活可扩展的 HTML5 构建工具
Home Page: https://elf.aotu.io
License: MIT License
灵活可扩展的 HTML5 构建工具
Home Page: https://elf.aotu.io
License: MIT License
因为使用的合成雪碧图的插件 postcss-sprites 的匹配图片的正则有点问题,等被修复后,更新
resolve: { alias: { vue: 'vue/dist/vue.js' } },
我添加了如下别名,但是不生效
elf command not found ,windows和mac都报错,已经全局安装了
本来想提交个PR 但是发现自己不会。算了
v1.8.0
windows
无
elf init 提示
elf-init(1) does not exist, try --help
1)安装失败
Phantom installation failed Error: end of central directory record signature not found
at /usr/local/lib/node_modules/elf-cli/node_modules/extract-zip/node_modules/yauzl/index.js:167:14
at /usr/local/lib/node_modules/elf-cli/node_modules/extract-zip/node_modules/yauzl/index.js:473:5
at /usr/local/lib/node_modules/elf-cli/node_modules/extract-zip/node_modules/fd-slicer/index.js:32:7
at FSReqCallback.wrapper [as oncomplete] (fs.js:477:5) Error: end of central directory record signature not found
at /usr/local/lib/node_modules/elf-cli/node_modules/extract-zip/node_modules/yauzl/index.js:167:14
at /usr/local/lib/node_modules/elf-cli/node_modules/extract-zip/node_modules/yauzl/index.js:473:5
at /usr/local/lib/node_modules/elf-cli/node_modules/extract-zip/node_modules/fd-slicer/index.js:32:7
at FSReqCallback.wrapper [as oncomplete] (fs.js:477:5)
2)phantomjs
这个包很耗时看这个能不能优化一下?
v1.9.0
windows
安装 node-sass 时指定了SASS_BINARY_SITE=https://npm.taobao.org/mirrors/node-sass/
但无法找到对应的已经编译好的版本
不好意思,又来打扰您了
webpack.base.js 中 webpack的 resolve 的 alias的配置如下:
alias:{ src: resolveApp('src') }
这里不明白在elf 中如何使用和表现的?src 为绝对路径吗?使用时机是什么时候?
还有个问题,现在在 html 页面写 img 标签时src中如果引入本地文件(相对路径)
<img src="./img/html5-logo.png">
start 或者 build 都会报错。
报的是/node_modules/pngquant-bin/vendor/pngquant失败。麻烦您给看看?
以下是错误信息:
ERROR in ./src/img/html5-logo.png Module build failed: Error: spawn /usr/local/lib/node_modules/elf-cli/node_modules/pngquant-bin/vendor/pngquant ENOENT at exports._errnoException (util.js:1008:11) at Process.ChildProcess._handle.onexit (internal/child_process.js:182:32) at onErrorNT (internal/child_process.js:348:16) at _combinedTickCallback (internal/process/next_tick.js:74:11) at process._tickCallback (internal/process/next_tick.js:98:9) @ ./src/index.html 1:1133-1164
帮帮新手,谢谢
模版下载404,不知道是啥原因
网站上的那几个demo在带触摸屏的电脑上不响应触摸屏滑动是怎么回事?
想问下对于 Retina 屏幕下1px的问题,脚手架中使用的是什么解决方案 ❓
有部份JS要单独加载,不想打包到bundle中,有办法设置吗?
使用elf init -t base 之后 zepto 默认是没有加载在页面的。是不是程序有问题?
webpack.base.js 中 webpack 插件配置的地方:
new webpack.ProvidePlugin({
$: zeptoPath,
Zepto: zeptoPath,
'window.Zepto': zeptoPath
})
常规加载使用路径
<video src="plugin/1.mp4"></video>
这样无法找到文件,如果使用下面的路径
<video src="../src/plugin/1.mp4"></video>
在浏览器里可以获取,但是在真机设备上无法显示
安装的时候,没有输入版本号
Ubuntu
SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
1.9.3
12.16.2
6.14.4
windows
Downloading template 一直没有进度
v1.9.1
windows 10 1803
node v9.4.0
npm v5.6.0
events.js:137
throw er; // Unhandled 'error' event
^
Error: listen EADDRINUSE :::8000
at Object._errnoException (util.js:1003:13)
at _exceptionWithHostPort (util.js:1024:20)
at Server.setupListenHandle [as _listen2] (net.js:1366:14)
at listenInCluster (net.js:1407:12)
at Server.listen (net.js:1495:7)
at Server.listen (D:\DevTool\nvm\v9.4.0\node_modules\elf-cli\node_modules\webpack-dev-server\lib\Server.js:479:47)
at runDevServer (D:\DevTool\nvm\v9.4.0\node_modules\elf-cli\src\start.js:71:13)
at run (D:\DevTool\nvm\v9.4.0\node_modules\elf-cli\src\start.js:88:3)
at Object.<anonymous> (D:\DevTool\nvm\v9.4.0\node_modules\elf-cli\src\start.js:92:1)
at Module._compile (module.js:660:30)
at Object.Module._extensions..js (module.js:671:10)
at Module.load (module.js:573:32)
at tryModuleLoad (module.js:513:12)
at Function.Module._load (module.js:505:3)
at Function.Module.runMain (module.js:701:10)
at startup (bootstrap_node.js:193:16)
npm失败
不论是全局代理还是淘宝,还是官方推荐都试过惹
MAC 跟 windows下面都不行
node v12.13.0
npm v6.12
Writing location.js file
Done. Phantomjs binary available at C:\Users\Hoga.SC-201910080547\AppData\Roaming\npm\node_modules\elf-cli\node_modules\ phantomjs-prebuilt\lib\phantom\bin\phantomjs.exe
[email protected] install C:\Users\Hoga.SC-201910080547\AppData\Roaming\npm\node_modules\elf-cli\node_modules\node-sass > node scripts/install.js
Downloading binary from https://npm.taobao.org/mirrors/node-sass//v4.5.3/win32-x64-72_binding.node
Cannot download "https://npm.taobao.org/mirrors/node-sass//v4.5.3/win32-x64-72_binding.node":
HTTP error 404 Not Found
‼ read ECONNRESET
‼ pngquant pre-build test failed
i compiling from source
√ pngquant pre-build test passed successfully
× Error: pngquant failed to build, make sure that libpng-dev is installed
at C:\Users\Hoga.SC-201910080547\AppData\Roaming\npm\node_modules\elf-cli\node_modules\pngquant-bin\node_modules\bin-build\node_modules\execa\index.js:231:11
at processTicksAndRejections (internal/process/task_queues.js:93:5)
at async Promise.all (index 0)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] postinstall: node lib/install.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
在哪里看到效果
1.9.1
window 10 64位 专业版
elf init demo
yarn
elf start
ERROR in C:/Users/DELL/AppData/Roaming/npm/node_modules/elf-cli/node_modules/css-loader?{}!C:/Users/DELL/AppData/Roaming/npm/node_modules/elf-cli/node_modules/postcss-loader/lib?{}!C:/Users/DELL/AppData/Roaming/npm/node_modules/elf-cli/node_modules/sass-loader/lib/loader.js!./src/css/package.scss
Module build failed: Error: Node Sass does not yet support your current environment: Windows 64-bit with Unsupported runtime (64)
For more information on which environments are supported please see:
https://github.com/sass/node-sass/releases/tag/v4.5.3
at module.exports (C:\Users\DELL\AppData\Roaming\npm\node_modules\elf-cli\node_modules\node-sass\lib\binding.js:13:13)
at Object.<anonymous> (C:\Users\DELL\AppData\Roaming\npm\node_modules\elf-cli\node_modules\node-sass\lib\index.js:14:35)
at Module._compile (internal/modules/cjs/loader.js:689:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
at Module.load (internal/modules/cjs/loader.js:599:32)
at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
at Function.Module._load (internal/modules/cjs/loader.js:530:3)
at Module.require (internal/modules/cjs/loader.js:637:17)
at require (internal/modules/cjs/helpers.js:22:18)
at Object.<anonymous> (C:\Users\DELL\AppData\Roaming\npm\node_modules\elf-cli\node_modules\sass-loader\lib\loader.js:3:14)
at Module._compile (internal/modules/cjs/loader.js:689:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
at Module.load (internal/modules/cjs/loader.js:599:32)
at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
at Function.Module._load (internal/modules/cjs/loader.js:530:3)
at Module.require (internal/modules/cjs/loader.js:637:17)
@ ./src/css/package.scss 4:14-371 18:2-22:4 19:20-377
@ ./src/js/main.js
@ multi (webpack)-dev-server/client?/ (webpack)/hot/dev-server.js src/js/main.js
Compiling fail!
1.9.1
node: v8.12.0
ERROR in js/bundle.js from UglifyJs
Unexpected token: name (ret) [js/bundle.js:107,8]
v1.9.1
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.102 Safari/537.36
无
如题orz
尝试改webpack配置,不让过有点无从下手。。。
你好,问题如题,设置中只找到publicPath。设置后html页面里的内容有加前缀,但css文件中引用的资源并没有,我不想把html文件缓存到cdn,所以想css中的引用也指向到cdn地址。
请问是否有此功能呢?
是由 webpack 的 issue 引起的
升级 webpack > 2.3.0 解决
package.json中的bin : elf为全局命令入口
在commander 中如何将elf build 指向 bin/elf-init.js文件的?(action)
谢谢
你好,有些问题想和你深度交流,不知道如何联系你?可否提供下邮箱
好像没看到有压缩包
1.9.1
window10 node 8.9.1
RT 关于微信分享的配置在哪里,没看出来。
如题。
手动删掉elf-cli里相关zepto配置,页面直接引入cdn解决。
1.9.1
类试transform: translate3d(-25%, 0, 0) rotate3d(0, 0, 1, -5deg)
css语句会被转换为2d
1.9.1
macOS
ERROR in js/bundle.js from UglifyJs
Unexpected token name «i», expected punc «;» [js/bundle.js:125,13]
module: {
loaders: [{
test: zeptoPath,
loader: 'exports?window.$!script'
}, {
test: /\.(mp3|mp4|webm|mov|ogg|ogv)(\?\S*)?$/,
exclude: /node_modules/,
loader: 'file-loader?' + JSON.stringify(config.audioLoaderQuery),
}, {
test: /\.html$/,
exclude: /node_modules/,
loader: 'html'
},{
test: /\.jsx?$/,
exclude: /(node_modules|bower_components)/,
loader: 'babel',
query: {
presets: ['es2015']
}
}]
}
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.