vscode package.json String does not match the pattern

前端 未结 2 2747
隐瞒了意图╮
隐瞒了意图╮ 2021-02-19 07:35

I am trying out VSCode on an existing project that uses npm and has a package.json file with a corresponding \"name:\" key that reads \"SpecPro-File-Management-UI\". VSCode is o

2条回答
  •  北恋
    北恋 (楼主)
    2021-02-19 08:02

    This behavior is by design to enforce NPM conventions for the package.json file (to paraphrase, "lower-case only"). I agree it is a nuisance, especially since the project name is often pre-filled, e.g. by "create-react-app". As you point out, it is possible to create a custom schema to ignore this, but it's really not recommended. There isn't any alternative at this time. Myself, I just change the value to lower-case.

提交回复
热议问题