javascript - 从命令行使用 rollup.js 时是否有监视选项

标签 javascript rollupjs

我正在使用 rollup.js 从文件“main.js”中转译模块依赖项

rollup main.js

是否有一个监视选项可以在源文件更改时重新运行转译

最佳答案

v0.29 开始,您可以使用 rollup --watch


不,还没有(command line options)。有一个issue opened for this just yesterday .

Rich-Harris 写道:

Agree. We intend to add some functionality around incremental builds (#191), and this would go hand-in-hand with that. The goal would be for the incremental build stuff to be flexible enough to integrate with existing build systems, but I think it'd make sense for the CLI to support it out of the box:

rollup -c --watch

关于javascript - 从命令行使用 rollup.js 时是否有监视选项,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33654682/

相关文章:

javascript - 在 Node 中验证 TypeForm Webhook 负载

javascript - 使用 jQuery 的 Dart JavaScript 互操作回调

javascript - 如何将 bower 包依赖项排除在我的汇总包之外?

javascript - 在 Rollup 中,如何让 --external 在直接指向要排除的模块的命令行上工作? (没有节点解析插件)

reactjs - React + Antd + Rollup 组件库 "Error: Invalid hook call. Hooks can only be called inside of the body of a function component"

reactjs - 摇树创建 react 应用程序?

javascript - 如何阻止 JQuery 中的默认选项卡切换功能?

JavaScript 使用正则表达式进行匹配

javascript - 如何在代码隐藏中访问 session 变量

css - 是否可以使用汇总来仅处理 css?