This template includes the following packages:
這模板整合了以下套件
- Axios - Promise based HTTP client for the browser and node.js
- Babel Compiler - Use next generation JavaScript, today.
- Dayjs - Fast 2kB alternative to Moment.js with the same modern API
- Element UI Plus - Element Plus, a Vue 3.0 based component library (Including Day.js)
- ESLint - Find and fix problems in your JavaScript code
- Json-Server - Get a full fake REST API with zero coding in less than 30 seconds (seriously)
- Stylelint - A mighty, modern linter that helps you avoid errors and enforce conventions in your styles.
- TestCafe - A node.js tool to automate end-to-end web testing
- TypeScript - TypeScript extends JavaScript by adding types.
- Vue 3 - The Progressive JavaScript Framework.
- Vue I18n - Vue I18n is internationalization plugin for Vue.js
- Vue Test Utils with Jest - Vue Test Utils is the official unit testing utility library for Vue.js.
請先安裝好 Node.js 環境
This Demo project is running on Node.js (12.20.0), NPM (6.14.9) while testing.
- Clone this repository to your local machine
- Start your development :)
$ git clone https://github.com/andy922200/vue3-typescript-jest-elementUI-testcafe.git
1. Enter the project folder
> Open a new terminal window and enter the folder
$ cd <project folder>
2. Install packages via npm
$ npm install
3. Compiles the webpack for development
$ npm run serve // port:8080
4. Fix the coding style automatically ( js / html )
$ npm run format
5. Check the css coding style
$ npm run check-css
6. Fix the css coding style automatically
$ npm run format-css
7. Execute Unit Test
$ npm run test-jest
8. Clean Unit Test Cache
$ npm run test-jest-clean
9. Execute E2E Test
$ npm run test-e2e