npm init error: Invalid name: "donn&jul"
10,337
From the official NPM reference:
The name ends up being part of a URL, an argument on the command line, and a folder name. Therefore, the name can't contain any non-URL-safe characters.
I believe &
is not url-safe.
Author by
Julius Tan
Updated on June 04, 2022Comments
-
Julius Tan almost 2 years
My
npm
version is2.5.1
and mynode
version is0.12.0
. When I try to runnpm init
, I get the following error:npm ERR! Invalid name: "donn&jul"
Here is the screenshot: .
Why is this happening?
-
Julius Tan about 9 yearsThanks for the quick reply!