npm installation

Step 1

Install the dependencies using:

npm install

# OR

yarn install

Installing with npm may require the use of the --legacy-peer-deps flag for some versions of npm.

In the new version of npm (v7), by default, npm install will fail when it encounters conflicting peerDependencies.

Take a look here for more info about peer dependencies in npm v7.

The differences between the two are below –

--legacy-peer-deps: ignore all peerDependencies when installing, in the style of npm version 4 through version 6.

--strict-peer-deps: fail and abort the install process for any conflicting peerDependencies when encountered. By default, npm will only crash for peerDependencies conflicts caused by the direct dependencies of the root project.

--force: will force npm to fetch remote resources even if a local copy exists on disk.

Step 2

Run the development server:

yarn start

# OR

npm run start
Step 3

Open http://localhost:3000 with your browser to see the result (if it doesn’t open automatically).

Now you can start editing pages or components. The page auto-updates as you edit and save a file.

To avoid any issues, please make sure you have the latest stable version of Node.js installed.

If you need to have multiple versions of Node.js installed, you can use nvm.

Was this article helpful to you?