GithubHelp home page GithubHelp logo

lionnnnn / vue2.7-vite-cli Goto Github PK

View Code? Open in Web Editor NEW

This project forked from only-xc/vue2.7-vite-cli

0.0 0.0 0.0 437 KB

Vue2.7 + Vite + Less + Eslint + Stylelint + Commitlint 工程化脚手架。

Home Page: https://only-xc.github.io/vue2.7-vite-cli/

Shell 1.05% JavaScript 49.49% CSS 5.11% HTML 1.70% Vue 39.66% Less 2.98%

vue2.7-vite-cli's Introduction

Vue 2.7 + Vite 脚手架

Vue2.7 已经发布正式版啦,不出意外的话这应该是 Vue2 的最后一个版本了,但是很多公司目前还没有升级 Vue3 的打算(比如我们)。

所以封装了这么一个开箱即用的脚手架模板,脚手架的功能可以看下面的功能列表小节,并且配备完整的技术文档。

可以直接使用,也可以当作学习源码。

教程目录

  1. 工程化实践
  2. 全家桶
  3. 更多功能

基础搭建

在这里我们使用的是 pnpm 来作为本项目的包管理工具。

# 安装依赖
pnpm i

# 运行
pnpm run dev

# 打包
pnpm run build

# 打包文件预览
pnpm run preview

本人开发环境

node v16.13.1(大于 14 版本即可)

pnpm v6.30.0

插件安装

此脚手架必须安以下依赖才能保证,代码自动格式化的有效运行:

  • Vetur
  • EditorConfig for VS Code
  • ESLint
  • Stylelint

功能列表

  • Vue2.7 + Vite
  • Eslint、Stylelint、Commitlint 统一开发规范
  • husky + lint-staged (git commit 时自动格式化代码)
  • Vue 全家桶集成
  • Axios 封装及接口管理
  • Css 样式处理
  • vite.config.js 基础配置
  • 跨域配置
  • 多环境变量配置
  • 浏览器构建兼容性

vue2.7-vite-cli's People

Contributors

only-xc avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.