Skip to content
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

feat: add prettier and eslint (#18) #30

Merged
merged 13 commits into from
Jun 29, 2023
29 changes: 29 additions & 0 deletions web/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
module.exports = {
env: {
browser: true,
es2021: true,
},
extends: [
'eslint:recommended',
'plugin:@typescript-eslint/recommended',
'plugin:vue/vue3-essential',
],
overrides: [
{
env: {
node: true,
},
files: ['.eslintrc.{js,cjs}'],
parserOptions: {
sourceType: 'script',
},
},
],
parserOptions: {
ecmaVersion: 'latest',
parser: '@typescript-eslint/parser',
sourceType: 'module',
},
plugins: ['@typescript-eslint', 'vue'],
rules: {},
};
14 changes: 14 additions & 0 deletions web/.prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
/dist/*
.local
.output.js
/node_modules/**

**/*.svg
**/*.sh
**/*.md
**/*.yml
*.html

/public/*
/build
/coverage
10 changes: 10 additions & 0 deletions web/.prettierrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
module.exports = {
printWidth: 80,
tabWidth: 4,
useTabs: false,
singleQuote: true,
semi: true,
trailingComma: 'all',
bracketSpacing: true,
arrowParens: 'avoid',
};
23 changes: 11 additions & 12 deletions web/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,17 +14,16 @@
See the License for the specific language governing permissions and
limitations under the License.
-->
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no ‘-->’


<html lang="en">
<head>
<meta charset="UTF-8">
<link rel="icon" href="/favicon.ico">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>OpenKF</title>
</head>
<body>
<div id="app"></div>
<script src="./wasm_exec.js"></script>
<script type="module" src="/src/main.js"></script>
</body>
<head>
<meta charset="UTF-8" />
<link rel="icon" href="/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>OpenKF</title>
</head>
<body>
<div id="app"></div>
<script src="./wasm_exec.js"></script>
<script type="module" src="/src/main.js"></script>
</body>
</html>
Loading