chore: added husky git hooks

This commit is contained in:
lstoeferle 2021-03-07 22:49:43 +01:00
parent af79780bfe
commit df3abe64a2
5 changed files with 14 additions and 1 deletions

1
.husky/.gitignore vendored Normal file
View File

@ -0,0 +1 @@
_

4
.husky/pre-commit Executable file
View File

@ -0,0 +1,4 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"
npm run lint

6
package-lock.json generated
View File

@ -2369,6 +2369,12 @@
"integrity": "sha1-ELMKOGCF9Dzt41PMj6fLDe7qZos=",
"dev": true
},
"husky": {
"version": "5.1.3",
"resolved": "https://registry.npmjs.org/husky/-/husky-5.1.3.tgz",
"integrity": "sha512-fbNJ+Gz5wx2LIBtMweJNY1D7Uc8p1XERi5KNRMccwfQA+rXlxWNSdUxswo0gT8XqxywTIw7Ywm/F4v/O35RdMg==",
"dev": true
},
"icss-replace-symbols": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/icss-replace-symbols/-/icss-replace-symbols-1.1.0.tgz",

View File

@ -1,6 +1,7 @@
{
"private": true,
"scripts": {
"postinstall": "husky install",
"dev": "vite",
"build": "vite build",
"lint": "eslint './src/**/*.{js,ts,tsx,vue,md}'",
@ -23,6 +24,7 @@
"eslint": "^7.21.0",
"eslint-plugin-prettier": "^3.3.1",
"eslint-plugin-vue": "^7.7.0",
"husky": "^5.1.3",
"prettier": "^2.2.1",
"typescript": "^4.2.3",
"vite": "^2.0.5",

View File

@ -1,7 +1,7 @@
<template>
<div id="app">
<Navbar />
<main id="app">
<main>
<RouterView />
</main>
</div>