Skip to content

litemall client power for vue -- init #157

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 19, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions litemall-vue/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
module.exports = {
root: true,
env: {
node: true
},
extends: ['plugin:vue/essential', '@vue/prettier'],
// rules: {
// camelcase: 'off',
// quotes: ['error', 'single'],
// indent: ['error', 2, { SwitchCase: 1 }],
// 'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off',
// 'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off'
// },
parserOptions: {
parser: 'babel-eslint'
}
};
21 changes: 21 additions & 0 deletions litemall-vue/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
.DS_Store
node_modules
/dist

# local env files
.env.local
.env.*.local

# Log files
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# Editor directories and files
.idea
.vscode
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw*
5 changes: 5 additions & 0 deletions litemall-vue/.postcssrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
module.exports = {
plugins: {
autoprefixer: {}
}
};
4 changes: 4 additions & 0 deletions litemall-vue/.prettierrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
module.exports = {
tabWidth: 2,
singleQuote: true
};
61 changes: 61 additions & 0 deletions litemall-vue/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
# liteMall 移动商城

- 本项目是小程序的 vue 版本,样式大体相同,欢迎有能力的人贡献更优秀的代码

> 使用有赞移动端 Vue 组件库 — [Vant](https://www.youzanyun.com/zanui/vant#/zh-CN/component/intro)


## Vue相关库与插件

- power by vue-cli3
- Vue + Vue-router + Vant + Sass
- axios
- vee-validate
- fastclick
- babel-polyfill
- @xkeshi/vue-countdown


## Build Script

``` bash
# install dependencies
npm install

# serve with hot reload at localhost:6255 九键输入法的 「mall」= 「6255」
npm run serve

# build for production with minification : build result at /dist
npm run build

# build for production and view the bundle analyzer report
npm run build -- --report
```

- 简单预览:

[![AqVx1g.md.png](https://s2.ax1x.com/2019/04/12/AqVx1g.md.png)](https://imgchr.com/i/AqVx1g)

[![AqZZ3F.md.gif](https://s2.ax1x.com/2019/04/12/AqZZ3F.md.gif)](https://imgchr.com/i/AqZZ3F)


### 一些 Tips

- 手机浏览或 chrome 手机模式:开发/浏览 体验更佳

- 运行项目

```bash
npm i && npm run serve
```

- 打包项目

```bash
# /dist copy to you http server
npm run build
```




15 changes: 15 additions & 0 deletions litemall-vue/babel.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
module.exports = {
presets: ['@vue/app'],
plugins: [
'lodash',
[
'import',
{
libraryName: 'vant',
libraryDirectory: 'es',
style: true
},
'vant'
]
]
};
Loading