-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Description
Subject
Multiple pages using npm install, pnpm add and yarn add
Description
Issue
Instructions for installing cypress and other npm modules are shown inconsistently throughout the website for npm, pnpm and Yarn package managers.
-
Sometimes the short-form of an optional flag is used and sometimes the long-form is used, e.g.
npm install cypress -D
- Getting Started > Installing Cypress > npm install uses the equivalent
--save-dev:
npm install cypress --save-dev
- Getting Started > Installing Cypress > npm install uses the equivalent
-
Sometimes an optional flag is positioned directly after
installand sometimes the same optional flag is positioned at the end of line, e.g.Continuous Integration > Introduction > Setting up CI > Boot your server > Solutions uses
--save-devdirectly afterinstall:npm install --save-dev start-server-and-test
Continuous Integration > Introduction > Setting up CI > Basics uses
--save-devat the end of line:npm install cypress --save-dev
Suggestions
Each of the examples are correct, however making the instructions consistent throughout the site avoids causing confusing about whether any differences are significant or not.
-
Suggest to standardize on long form for optional flags, e.g.
--save-dev. This makes for better comprehension for readers unfamiliar with the meaning of the alternative short-form optional flag. -
Align the positioning of the optional flag to the package manager documentation. For instance, npm CLI >
npm-install> Description shows--save-devused at the end of the line in its example:npm install node-tap --save-dev
Most of the examples use npm install. A few examples use yarn add and just one example uses pnpm add.