【问题标题】:Executing pug from local node_modules从本地 node_modules 执行 pug
【发布时间】:2017-06-25 21:18:11
【问题描述】:

我正在尝试从 node_modules 执行 pug (/jade),但我没有在 node_modules/.bin 文件夹中找到可执行文件。 我使用的是 MacOS 10.12.5,并通过“npm install --save pug”命令安装了 pug。 如何在没有全局安装的情况下从 node_modules 文件夹执行 pug 命令?

【问题讨论】:

    标签: javascript node.js npm pug


    【解决方案1】:

    要从命令行使用 pug,您必须安装 pug-cli。

    作为本地包:npm install pug-cli --save

    作为一个全局包:npm install pug-cli -g

    更多信息:https://github.com/pugjs/pug-cli#installation

    【讨论】:

    • 谢谢,我没想到我需要 pug-cli 而不是 pug。
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2017-12-28
    • 1970-01-01
    • 2018-04-24
    • 1970-01-01
    • 2023-01-22
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多