Skip to content

Commit

Permalink
build($exrx-net-crawler): initial project
Browse files Browse the repository at this point in the history
Feature:
 - Vuetify, TypeScript
 - Axios, support CORS
 - Parse DOM, marge DOM nodes
 - Communicate with back-end server
 - Multi-environment support
 - Multi-lingual (internationalisation)
 - Lazy router
 - NGINX support
 - Beatified noscript content

BREAKING CHANGE: implemented infra web scraping
  • Loading branch information
johnnymillergh committed Jan 16, 2020
0 parents commit 8afa70c
Show file tree
Hide file tree
Showing 78 changed files with 3,749 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .browserslistrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
> 1%
last 2 versions
14 changes: 14 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# http://editorconfig.org
root = true

[*]
charset = utf-8
indent_style = space
indent_size = 2
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true

[*.md]
insert_final_newline = false
trim_trailing_whitespace = false
5 changes: 5 additions & 0 deletions .env
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Package JSON string for globally access attention
VUE_APP_PACKAGE_JSON=''

# TAG must be corresponding with the version tag in package.json, need to modify it when new version releases
TAG=1.0.0-beta
25 changes: 25 additions & 0 deletions .env.development
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# NODE_ENV can only be 'development' or 'production'.
# If set other value, packaged resource would be difference between environment.
NODE_ENV = 'development'
# Just a flag
VUE_APP_ENV = 'dev'
# Whether application is running on docker
VUE_APP_RUN_ON_DOCKER = 'false'

# Backend server IP and port. It's required when the environment is development.
# Left blank if the environment is not development.
VUE_APP_BASE_URL = 'http://localhost:8080'
# Base api
VUE_APP_BASE_API = '/exrx-net-crawler-server-dev_loc'
# Resource base api for picture, video ect.
VUE_APP_RESOURCE_BASE_API = 'http://localhost:8080/exrx-net-crawler-server-dev_loc'

VUE_APP_EXRX_NET_BASE_URL = 'http://exrx.net'

# vue-cli uses the VUE_CLI_BABEL_TRANSPILE_MODULES environment variable,
# to control whether the babel-plugin-dynamic-import-node plugin is enabled.
# It only does one thing by converting all import() to require().
# This configuration can significantly increase the speed of hot updates,
# when you have a large number of pages.
# Detail: https://github.com/vuejs/vue-cli/blob/dev/packages/@vue/babel-preset-app/index.js
VUE_CLI_BABEL_TRANSPILE_MODULES = true
15 changes: 15 additions & 0 deletions .env.development_docker
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# NODE_ENV can only be 'development' or 'production'.
# If set other value, packaged resource would be difference between environment.
NODE_ENV = 'production'
# Just a flag
VUE_APP_ENV = 'dev_dkr'
# Whether application is running on docker
VUE_APP_RUN_ON_DOCKER = 'true'

# Backend server IP and port. It's required when the environment is development.
# Left blank if the environment is not development.
VUE_APP_BASE_URL = ''
# Base api
VUE_APP_BASE_API = 'http://localhost:8081/jm-spring-boot-template-dev_dkr'
# Resource base api for picture, video ect.
VUE_APP_RESOURCE_BASE_API = 'http://localhost:8081/jm-spring-boot-template-dev_dkr'
15 changes: 15 additions & 0 deletions .env.production
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# NODE_ENV can only be 'development' or 'production'.
# If set other value, packaged resource would be difference between environment.
NODE_ENV = 'production'
# just a flag
VUE_APP_ENV = 'prod'
# Whether application is running on docker
VUE_APP_RUN_ON_DOCKER = 'true'

# Backend server IP and port. It's required when the environment is development.
# Left blank if the environment is not development.
VUE_APP_BASE_URL = ''
# Base api
VUE_APP_BASE_API = 'http://106.13.32.85:8081/jm-spring-boot-template-prod'
# Resource base api for picture, video ect.
VUE_APP_RESOURCE_BASE_API = 'http://106.13.32.85:8081/jm-spring-boot-template-prod'
15 changes: 15 additions & 0 deletions .env.stage
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# NODE_ENV can only be 'development' or 'production'.
# If set other value, packaged resource would be difference between environment.
NODE_ENV = 'production'
# just a flag
VUE_APP_ENV = 'stage'
# Whether application is running on docker
VUE_APP_RUN_ON_DOCKER = 'true'

# Backend server IP and port. It's required when the environment is development.
# Left blank if the environment is not development.
VUE_APP_BASE_URL = ''
# Base api
VUE_APP_BASE_API = 'http://localhost/jm-spring-boot-template-stage'
# Resource base api for picture, video ect.
VUE_APP_RESOURCE_BASE_API = 'http://localhost/jm-spring-boot-template-stage'
15 changes: 15 additions & 0 deletions .env.test
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# NODE_ENV can only be 'development' or 'production'.
# If set other value, packaged resource would be difference between environment.
NODE_ENV = 'production'
# just a flag
VUE_APP_ENV = 'test'
# Whether application is running on docker
VUE_APP_RUN_ON_DOCKER = 'true'

# Backend server IP and port. It's required when the environment is development.
# Left blank if the environment is not development.
VUE_APP_BASE_URL = ''
# Base api
VUE_APP_BASE_API = 'http://localhost/jm-spring-boot-template-test'
# Resource base api for picture, video ect.
VUE_APP_RESOURCE_BASE_API = 'http://localhost/jm-spring-boot-template-test'
4 changes: 4 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
build/*.js
src/assets
public
dist
69 changes: 69 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
module.exports = {
root: true,
env: {
es6: true,
node: true
},
'extends': [
'plugin:vue/essential',
// 'plugin:vue/recommended',
'@vue/standard',
'@vue/typescript',
'plugin:@typescript-eslint/eslint-recommended'
],
plugins: ['vue-libs'],
rules: {
'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off',
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',

'space-before-function-paren': [
2,
'always'
],

'indent': 'off',
'@typescript-eslint/indent': ['error', 2],

'@typescript-eslint/member-delimiter-style': ['error', {
multiline: {
delimiter: 'none',
requireLast: false
},
singleline: {
delimiter: 'semi',
requireLast: false
}
}],

'semi': 'off',
'@typescript-eslint/semi': ['error', 'never'],

'prefer-const': 2,
'object-curly-spacing': [2, 'always', { objectsInObjects: false }],
'array-bracket-spacing': [2, 'never'],
'vue-libs/jsx-uses-vars': 2,
'vue/require-v-for-key': 0,
'vue/html-indent': 'error',
'vue/html-quotes': 'error',
'vue/mustache-interpolation-spacing': 'error',
'vue/html-self-closing': 'error',
'no-unused-vars': 'error',
'yoda': 'off'
},
parserOptions: {
parser: '@typescript-eslint/parser',
ecmaVersion: 2020,
sourceType: 'module'
},
overrides: [
{
files: [
'**/__tests__/*.{j,t}s?(x)',
'**/tests/unit/**/*.spec.{j,t}s?(x)'
],
env: {
jest: true
}
}
]
}
23 changes: 23 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
### Customized ingore directories and files ###
.DS_Store
node_modules
/dist
/package-lock.json

### 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?
11 changes: 11 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
language: node_js
node_js:
- node
install:
- npm install
script:
- npm run go:travis
notifications:
email:
on_failure: change
on_success: change
Loading

0 comments on commit 8afa70c

Please sign in to comment.