All Products
Search
Document Center

Build front-end development workspace

Last Updated: May 25, 2021

Node.js and cnpm need to be installed for the front-end development workspace. This topic guides you to build environments for different operating systems. If you use Windows operating system, you need to complete user configuration first.

Build front-end development workspace in Windows

  1. Complete Windows user configuration. Follow the figure below to install the MinGW command prompt. Download the installation file at git-scm.undefined
  2. Download and install Node.js v8.
  3. Install cnpm.

    1. In MinGW or on a terminal, run the following command to install cnpm:

           
      1. npm install -g cnpm --registry=https://registry.npm.taobao.org
      Note: Do not install cnpm in alias method that is used for adding the npm parameter. For more information about cnpm, see Taobao NPM mirror.
    2. After cnpm is installed, run the following command to verify the installation.

           
      1. cnpm -v
      2. cnpm@6.1.0 (C:\Users\wb-wly538545\AppData\Roaming\npm\node_modules\cnpm\lib\parse_argv.js)
      3. npm@6.11.3 (C:\Users\wb-wly538545\AppData\Roaming\npm\node_modules\cnpm\node_modules\npm\lib\npm.js)
      4. node@8.11.1 (D:\Program Files (x86)\nodejs\node.exe)
      5. npminstall@3.23.0 (C:\Users\wb-wly538545\AppData\Roaming\npm\node_modules\cnpm\node_modules\npminstall\lib\index.js)
      6. prefix=C:\Users\wb-wly538545\AppData\Roaming\npm
      7. win32 ia32 10.0.17134
      8. registry=https://r.npm.taobao.org

Build front-end development workspace in macOS

  1. Download and install Node.js v8.
  2. Install cnpm.

    1. In MinGW or on a terminal, run the following command to install cnpm:

           
      1. npm install -g cnpm --registry=https://registry.npm.taobao.org
      Note: Do not install cnpm in alias method that is used for adding the npm parameter. For more information about cnpm, see Taobao NPM mirror.
    2. After cnpm is installed, run the following command to verify the installation.

           
      1. cnpm -v
      2. cnpm@6.1.0 (C:\Users\wb-wly538545\AppData\Roaming\npm\node_modules\cnpm\lib\parse_argv.js)
      3. npm@6.11.3 (C:\Users\wb-wly538545\AppData\Roaming\npm\node_modules\cnpm\node_modules\npm\lib\npm.js)
      4. node@8.11.1 (D:\Program Files (x86)\nodejs\node.exe)
      5. npminstall@3.23.0 (C:\Users\wb-wly538545\AppData\Roaming\npm\node_modules\cnpm\node_modules\npminstall\lib\index.js)
      6. prefix=C:\Users\wb-wly538545\AppData\Roaming\npm
      7. win32 ia32 10.0.17134
      8. registry=https://r.npm.taobao.org