Skip to content
This repository has been archived by the owner on Aug 21, 2019. It is now read-only.

Commit

Permalink
添加文档网站 (#126)
Browse files Browse the repository at this point in the history
[new feature] Doc: 添加文档网站
  • Loading branch information
realywithoutname authored and pangxie1991 committed Feb 13, 2018
1 parent 56605cc commit 37cdd28
Show file tree
Hide file tree
Showing 53 changed files with 10,612 additions and 1 deletion.
206 changes: 206 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 6 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@
"components": "node scripts/build-components.js --color",
"changelog": "sh scripts/build-changelog.sh",
"icon": "sh scripts/build-icon.sh",
"dev": "node scripts/build-dev.js --color"
"dev": "node scripts/build-dev.js --color",
"build": "sh scripts/deploy.sh",
"deploy": "npm run build && superman cdn basic && gh-pages -d website/dist --remote youzan"
},
"repository": {
"type": "git",
Expand All @@ -38,5 +40,8 @@
"postcss-easy-import": "^3.0.0",
"precss": "^2.0.0",
"shelljs": "^0.7.8"
},
"dependencies": {
"gh-pages": "^1.1.0"
}
}
7 changes: 7 additions & 0 deletions scripts/deploy.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
cd website && yarn && yarn cache node_modules

npm run build

cd ../


8 changes: 8 additions & 0 deletions superman.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"cdn": {
"basic": {
"src": ["website/dist/**/*.*"],
"dist": "zanui/weapp"
}
}
}
18 changes: 18 additions & 0 deletions website/.babelrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"presets": [
["env", {
"modules": false,
"targets": {
"browsers": ["> 1%", "last 2 versions", "not ie <= 8"]
}
}],
"stage-2"
],
"plugins": ["transform-vue-jsx", "transform-runtime"],
"env": {
"test": {
"presets": ["env", "stage-2"],
"plugins": ["transform-vue-jsx", "transform-es2015-modules-commonjs", "dynamic-import-node"]
}
}
}
9 changes: 9 additions & 0 deletions website/.editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
root = true

[*]
charset = utf-8
indent_style = space
indent_size = 2
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
6 changes: 6 additions & 0 deletions website/.eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
/build/
/config/
/dist/
/*.js
/test/unit/coverage/
/src/components/vant-doc
29 changes: 29 additions & 0 deletions website/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
// https://eslint.org/docs/user-guide/configuring

module.exports = {
root: true,
parserOptions: {
parser: 'babel-eslint'
},
env: {
browser: true,
},
extends: [
// https://github.com/vuejs/eslint-plugin-vue#priority-a-essential-error-prevention
// consider switching to `plugin:vue/strongly-recommended` or `plugin:vue/recommended` for stricter rules.
'plugin:vue/essential',
// https://github.com/standard/standard/blob/master/docs/RULES-en.md
'standard'
],
// required to lint *.vue files
plugins: [
'vue'
],
// add your custom rules here
rules: {
// allow async-await
'generator-star-spacing': 'off',
// allow debugger during development
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off'
}
}
17 changes: 17 additions & 0 deletions website/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
.DS_Store
node_modules/
/dist/
npm-debug.log*
yarn-debug.log*
yarn-error.log*
/test/unit/coverage/
/test/e2e/reports/
selenium-debug.log

# Editor directories and files
.idea
.vscode
*.suo
*.ntvs*
*.njsproj
*.sln
10 changes: 10 additions & 0 deletions website/.postcssrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
// https://github.com/michael-ciniawsky/postcss-load-config

module.exports = {
"plugins": {
"postcss-import": {},
"postcss-url": {},
// to edit target browsers: use "browserslist" field in package.json
"autoprefixer": {}
}
}
Loading

0 comments on commit 37cdd28

Please sign in to comment.