Giter Club home page Giter Club logo

bruce-cli's Introduction

bruce-cli

请查看Bruce FEES@yangzw/bruce-app的文档


经过两年时间对@yangzw/bruce-app进行艰苦的迭代,bruce-cli终于退休,后续不再维护。请大家使用最新版本的bruce-cli,其内部代码从@yangzw/bruce-app中移植过来,后续bruce-cli所有版本均和@yangzw/bruce-app同步,不再区分。

bruce-cli's People

Contributors

jowayyoung avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

bruce-cli's Issues

能否提供类似 create-react-app eject这样的命令

npm run eject可以移除项目对react-scripts的依赖,将webpack,Babel等的配置文件导入进项目中,bruce-cli
是否有类似的功能
create-react-app 文档如下:

npm run eject

Note: this is a one-way operation. Once you eject, you can’t go back!

If you aren’t satisfied with the build tool and configuration choices, you can eject at any time. This command will remove the single build dependency from your project.

Instead, it will copy all the configuration files and the transitive dependencies (Webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except eject will still work, but they will point to the copied scripts so you can tweak them. At this point you’re on your own.

You don’t have to ever use eject. The curated feature set is suitable for small and middle deployments, and you shouldn’t feel obligated to use this feature. However we understand that this tool wouldn’t be useful if you couldn’t customize it when you are ready for it.

polyfill.min.js 如何打包进本地文件

为什么我编译的生产代码中引用了 https://cdn.polyfill.io/v2/polyfill.min.js 这个cdn

这个 js 资源只有 2.3k 但是走了这个cdn后需要1s以上的响应时间,严重影响了首屏加载速度,create-react-app 则未发现此问题.

bruce b 选项如下:
? 请选择构建环境 生产环境
? 请确认是否输出ES6代码 Yes
? 请确认是否动态导入垫片 Yes
? 请确认是否哈希文件名称 Yes
? 请确认是否深度压缩文件 Yes
? 请确认是否时间化根目录 Yes
? 请确认是否分析打包结果 Yes
? 请确认是否上传到服务器 No

可以修改webpack的配置吗?

在导入element ui后构建会报Module parse failed: Unexpected character ' '的错,找到的答案是要webpack.config.js中module=>rules加上配置规则
在导入ant-design-vue的时候,设置按需加载要配置.babelrc or babel-loader option
所以可以自定义webpack的配置吗?

突然不好使了,报“permission denied”

上午打开vscode,提示Oh My Zsh更新,敲了Y
然后跑bruce b,就出现如下错误:
(node:18651) UnhandledPromiseRejectionWarning: Error: EACCES: permission denied, unlink '/usr/local/lib/node_modules/bruce-cli/.gitattributes'
(Use node --trace-warnings ... to show where the warning was created)
(node:18651) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag --unhandled-rejections=strict (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:18651) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

到现在还是一脸懵逼,只能向大神求救了

bruce b 报错

× Webpack Build
Compiled with some errors in 2.28s

clean-webpack-plugin: pausing due to webpack errors
Hash: c2322a2f782e38b33d58
Version: webpack 4.44.2
Time: 2280ms
Built at: 2020/11/25 下午3:37:17
Asset Size Chunks Chunk Names
vendor.dll.js 125 KiB 0 vendor
Entrypoint vendor = vendor.dll.js

ERROR in vendor.dll.js from UglifyJs
undefined

× 动态链接库构建失败

怎么设置publicPath?

移除publicPathProd和publicPathTest两个参数,打包文件引用路径统一使用绝对路径

请问这个绝对路径怎么配置?

cmd执行bruce b构建项目发生错误直接卡住不动了,什么都不显示,过了几分钟ctrl+c停止。再执行bruce b,报错找不到全局安装的bruce。js

执行完bruce b之后,全局安装的bruce被卸载了

C:\Users\Administrator\Desktop\app>bruce b
internal/modules/cjs/loader.js:983
throw err;
^

Error: Cannot find module 'C:\node-v12.16.2-win-x64\node_modules\bruce-cli\bin\bruce.js'
�[90m at Function.Module._resolveFilename (internal/modules/cjs/loader.js:980:15)�[39m
�[90m at Function.Module._load (internal/modules/cjs/loader.js:862:27)�[39m
�[90m at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:74:12)�[39m
�[90m at internal/main/run_main_module.js:18:47�[39m {
code: �[32m'MODULE_NOT_FOUND'�[39m,
requireStack: []
}

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.