What is cross – env

Run scripts that set up cross-platform and use environment variables

A reason for

Most Windows command prompts will block (error) when you use NODE_ENV =production to set environment variables. (The exception is Bash on Windows, which uses native Bash.) There are also differences in how Windows and POSIX commands use environment variables. With POSIX, you can use: $ENV_VAR and Windows with % ENV_VAR %. In English: Windows does not support NODE_ENV=development. complains

To solve

Cross-env lets you use a single command without having to worry about setting up or using environment variables correctly for the platform. Just run it on a POSIX system, and cross-env will set it up correctly. In English: this mini-package (cross-env) provides a script for setting environment variables, which allows you to set environment variables in Unix mode and then run compatible on Windows.