Skip to content

[DOCS] npm init doesn't use @latest package version if already installed globally #3821

@slorber

Description

@slorber

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

Run npm init docusaurus -- -V

image

publish 0.0.6

Run again:

image


I have no idea why it says:

Need to install the following packages:
  create-docusaurus
Ok to proceed? (y)

It even shows a download progress bar, and then the version stays at 0.0.5, despite 0.0.6 being published.

image

Expected Behavior

After 0.0.6 publish, it should use that newly published version instead of the already installed one.

This is also the behavior of yarn create docusaurus -V

Steps To Reproduce

See above

Environment

  • OS: MacOS
  • Node: 16.10
  • npm: 7.24.0

Could also reproduce on npm 6 / Node 12

Metadata

Metadata

Assignees

Labels

Bugthing that needs fixingPriority 1high priority issueRelease 7.xwork is associated with a specific npm 7 release

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions