Skip to content

Commit

Permalink
feat: add static code analyzer and eslint
Browse files Browse the repository at this point in the history
  • Loading branch information
gearsdigital committed Nov 29, 2021
1 parent 94adfec commit 0c10eb8
Show file tree
Hide file tree
Showing 5 changed files with 3,821 additions and 1,180 deletions.
56 changes: 56 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
module.exports = {
extends: ["plugin:vue/recommended", "plugin:prettier-vue/recommended", "prettier"],

settings: {
"prettier-vue": {
// Settings for how to process Vue SFC Blocks
SFCBlocks: {
/**
* Use prettier to process `<template>` blocks or not
*
* If set to `false`, you may need to enable those vue rules that are disabled by `eslint-config-prettier`,
* because you need them to lint `<template>` blocks
*
* @default true
*/
template: true,

/**
* Use prettier to process `<script>` blocks or not
*
* If set to `false`, you may need to enable those rules that are disabled by `eslint-config-prettier`,
* because you need them to lint `<script>` blocks
*
* @default true
*/
script: true,

/**
* Use prettier to process `<style>` blocks or not
*
* @default true
*/
style: true,
},
usePrettierrc: true,
fileInfoOptions: {
withNodeModules: false,
},
},
},

rules: {
"prettier-vue/prettier": [
"error",
{
// Override all options of `prettier` here
// @see https://prettier.io/docs/en/options.html
printWidth: 100,
singleQuote: false,
semi: true,
trailingComma: "es5",
bracketSameLine: true,
},
],
},
};
2 changes: 2 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
build
coverage
1 change: 1 addition & 0 deletions .prettierrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}
Loading

0 comments on commit 0c10eb8

Please sign in to comment.