yarn install only production code example
Example 1: yarn add install all packages in package,json
yarn install
Example 2: yarn install production only
yarn install --production
# OR
yarn install --production=true
# OR
yarn install --prod
Example 3: install dev dependency yarn
yarn add nameOfPackage --dev
Example 4: yarn install production only
NODE_ENV=production yarn install