我已经安装了Loopbackjs,并且在尝试运行lb4时 命令它显示错误。
lb4: The term 'lb4' is not recognized as the name of a cmdlet,
> function, script file, or operable program. Check the spelling of the
> name, or if a path was included, verify that the path is correct and
> try again. At line:1 char:1
> + lb4 app
> + ~~~
> + CategoryInfo : ObjectNotFound: (lb4:String) [], CommandNotFoundException
> + FullyQualifiedErrorId : CommandNotFoundException
>
> lb4: The term 'lb4' is not recognized as the name of a cmdlet,
> function, script file, or operable program. Check the spelling of the
> name, or if a path was included, verify that the path is correct and
> try again. At line:1 char:1
> + lb4 app
> + ~~~
> + CategoryInfo : ObjectNotFound: (lb4:String) [], CommandNotFoundException
> + FullyQualifiedErrorId : CommandNotFoundException
答案 0 :(得分:0)
CLI工具lb4
随npm软件包@loopback/cli
一起提供。您需要全局安装此软件包。参见Getting Started:
第2步
安装LoopBack 4 CLI
LoopBack 4 CLI是一个命令行界面,可以支持项目或扩展。 CLI提供了遵循最佳实践的LoopBack 4项目入门的最快方法。
$ npm install -g @loopback/cli
答案 1 :(得分:0)
Blockquote 如果您遇到此类问题,请确保npm已全局安装。并检查节点是否已正确安装。