A fullstack demo used Vue2 & Koa2(Koa1 version is here)
☀️ Easy to setup and learn
💯 Api test coverage
🚀 Instant feedback
😜 Vue SSR Support in the ssr branch
View the article for more details.
If you want to check the info of the test, view the article for more details.
git clone https://github.com/Molunerfinn/vue-koa-demo.git
npm install
or yarn
Also you need to install MySQL & create a database named todolist
,and execute 2 sql files list.sql
& user.sql
.Their are in sql/
After that, create a .env
file and set the database username & password:
DB_USER=XXXX # your database username
DB_PASSWORD=YYYY # your database
PORT=8889 # Koa is listening to this port
If you want to run the test for the Project, please create a .env.test
file to face this situation:
DB_USER=XXXX # your database username
DB_PASSWORD=YYYY # your database
PORT=8888 # The port which is listened by koa in the test environment
Beacuse of using Koa2, Node.js >= v7.6.0
is needed.
npm run dev
&& npm run server
open browser: localhost:8080
tips: login password is 123
npm run build
and then npm run server
open browser: localhost:8889
tips: login password is 123
npm run test
and find the coverage report in the coverage/lcov/index.html
Copyright (c) 2017 Molunerfinn