Skip to content

Commit

Permalink
added js api
Browse files Browse the repository at this point in the history
  • Loading branch information
miya0001 committed May 30, 2020
1 parent 667ce0e commit 16b0131
Show file tree
Hide file tree
Showing 6 changed files with 9,396 additions and 166 deletions.
15 changes: 15 additions & 0 deletions .babelrc
@@ -0,0 +1,15 @@
{
"plugins": ["@babel/plugin-transform-classes"],
"presets": [
[
"@babel/preset-env",
{
"targets": {
"ie": "11"
},
"useBuiltIns": "usage",
"corejs": 3
}
]
]
}
3 changes: 3 additions & 0 deletions .eslintignore
@@ -0,0 +1,3 @@
/node_modules/
/docs
/dist
91 changes: 91 additions & 0 deletions .eslintrc.js
@@ -0,0 +1,91 @@
module.exports = {
env: {
browser: true,
commonjs: true,
es6: true,
node: true,
mocha: true,
},
extends: ['eslint:recommended'],
parserOptions: {
ecmaVersion: 2018,
sourceType: 'module',
},
rules: {
'array-callback-return': ['error'],
'quote-props': ['error', 'as-needed'],
'arrow-parens': ['error', 'as-needed'],
'arrow-spacing': ['error', { before: true, after: true }],
'brace-style': ['error', '1tbs', { allowSingleLine: true }],
'comma-spacing': ['error', { before: false, after: true }],
'comma-dangle': [
'error',
{
arrays: 'always-multiline',
objects: 'always-multiline',
imports: 'always-multiline',
exports: 'always-multiline',
functions: 'always-multiline',
},
],
eqeqeq: ['error', 'always'],
indent: ['error', 2, { SwitchCase: 1 }],
'jsx-quotes': ['error', 'prefer-double'],
'valid-jsdoc': ['off'],
'key-spacing': ['off'],
'keyword-spacing': ['error'],
'linebreak-style': ['error', 'unix'],
'no-dupe-args': ['error'],
'no-console': ['warn'],
'no-const-assign': ['error'],
'no-irregular-whitespace': [
'error',
{
skipStrings: true,
skipComments: true,
skipRegExps: true,
skipTemplates: true,
},
],
'no-unused-vars': ['error'],
'no-undefined': ['error'],
'no-var': ['error'],
'no-multiple-empty-lines': ['error'],
'object-curly-spacing': ['error', 'always'],
'require-jsdoc': [
'off',
{
require: {
ArrowFunctionExpression: true,
ClassDeclaration: true,
FunctionDeclaration: true,
MethodDefinition: true,
},
},
],
quotes: ['error', 'single'],
semi: ['error', 'never'],
'spaced-comment': [
'error',
'always',
{
line: {
markers: ['/'],
exceptions: ['-', '+'],
},
block: {
markers: ['!'],
exceptions: ['*'],
balanced: true,
},
},
],
'space-before-blocks': [
'error',
{ functions: 'always', keywords: 'always', classes: 'always' },
],
'space-unary-ops': ['error'],
'space-infix-ops': ['error', { int32Hint: false }],
'sort-imports': ['off'],
},
}

0 comments on commit 16b0131

Please sign in to comment.