zoukankan      html  css  js  c++  java
  • 【NPM】使用学习

    【NPM】使用学习

    转载:

    目录

    ==============================================

    1、修改 npm 模块的安装路径

    2、淘宝 NPM 镜像

    3、vue-cli

    ==============================================

    1、修改 npm 模块的安装路径

    在 npm 安装目录下找到 npmrc 文件,修改要安装的路径前缀

    prefix=D: odejs ode_modules pm

    2、淘宝 NPM 镜像

    $ npm install -g cnpm --registry=https://registry.npm.taobao.org

    删除

    $ npm uninstall -g cnpm

    3、vue-cli

    $ npm install -g @vue/cli

    删除

    $ npm uninstall -g @vue/cli

    创建工程

    $ vue create my-project
    # OR
    $ vue ui

    npm run XXX是执行配置在package.json中的脚本,比如:

    "scripts": {
        "serve": "vue-cli-service serve",
        "build": "vue-cli-service build",
        "lint": "vue-cli-service lint",
        "analyz": "npm_config_report=true npm run build",
        "test:unit": "vue-cli-service test:unit",
        "test:e2e": "vue-cli-service test:e2e"
    }

    构建

    npm run build

    开发

    npm run dev
  • 相关阅读:
    php 基本符号
    php-fpm 启动和关闭
    php redis安装
    nginx 的安装
    Windows下Nginx的安装与配置
    apache 限制IP网段访问
    解决mysql导入导出数据乱码问题
    log_bin_trust_function_creators错误解决
    Mysqlbinlog使用
    通过yum安装Nagios
  • 原文地址:https://www.cnblogs.com/yangchongxing/p/10631364.html
Copyright © 2011-2022 走看看