Skip to content

Commit

Permalink
add prettier
Browse files Browse the repository at this point in the history
  • Loading branch information
lagden committed Nov 8, 2023
1 parent 79cd38a commit cc7cbaf
Show file tree
Hide file tree
Showing 12 changed files with 2,444 additions and 27 deletions.
15 changes: 15 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
*.css
.*
bin
build
coverage
dist
node_modules
package
# template.js
vite.config.js.timestamp-*

*.json
*.yaml
*.yml
*.md
16 changes: 16 additions & 0 deletions .prettierrc.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
arrowParens: avoid
bracketSameLine: false
bracketSpacing: false
# embeddedLanguageFormatting: auto
insertPragma: false
htmlWhitespaceSensitivity: css
printWidth: 720
proseWrap: preserve
quoteProps: as-needed
requirePragma: false
semi: false
singleAttributePerLine: true
singleQuote: true
trailingComma: all
tabWidth: 4
useTabs: true
2 changes: 1 addition & 1 deletion _init
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

npx tiged lagden/boilerplate-bin/files#main bin --force
npx tiged lagden/boilerplate-envs/files#main .conf --force
npx tiged lagden/boilerplate-eslint/files/backend#main . --force
# npx tiged lagden/boilerplate-eslint/files/backend#main . --force
npx tiged lagden/boilerplate-docker-nodejs/files#main . --force
cp .conf/base.back.sh .conf/base.sh
cp .conf/development.back.sh .conf/development.sh
Expand Down
2 changes: 2 additions & 0 deletions cli/listen.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,14 @@ import la from '@tadashi/local-access'
import * as debug from '@tadashi/debug'
import app from '../server/app.js'

// prettier-ignore
const {
PORT: port = 5001,
HOSTNAME_CUSTOM: hostname = '0.0.0.0',
VERSION = 'dev',
} = process.env

// prettier-ignore
const {
local,
network,
Expand Down
36 changes: 19 additions & 17 deletions coverage/lcov.info
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
TN:
SF:server/app.js
FN:14,cors
FN:24,maskError
FN:36,session
FN:22,maskError
FN:34,session
FNF:3
FNH:3
FNDA:4,cors
Expand All @@ -27,8 +27,8 @@ DA:16,4
DA:17,4
DA:18,4
DA:19,4
DA:20,4
DA:21,4
DA:20,1
DA:21,1
DA:22,1
DA:23,1
DA:24,1
Expand All @@ -49,14 +49,12 @@ DA:38,1
DA:39,1
DA:40,1
DA:41,1
DA:42,1
DA:43,1
LF:43
LH:43
LF:41
LH:41
BRDA:1,0,0,1
BRDA:14,1,0,4
BRDA:24,2,0,1
BRDA:36,3,0,3
BRDA:22,2,0,1
BRDA:34,3,0,3
BRF:4
BRH:4
end_of_record
Expand All @@ -80,21 +78,25 @@ DA:13,1
DA:14,1
DA:15,1
DA:16,1
DA:17,2
DA:18,2
DA:17,1
DA:18,1
DA:19,1
DA:20,1
DA:21,1
DA:22,1
DA:21,2
DA:22,2
DA:23,1
DA:24,1
DA:25,1
DA:26,1
DA:27,1
LF:27
LH:27
DA:28,1
DA:29,1
DA:30,1
DA:31,1
LF:31
LH:31
BRDA:1,0,0,1
BRDA:16,1,0,2
BRDA:20,1,0,2
BRF:2
BRH:2
end_of_record
Expand Down
7 changes: 5 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,9 @@
"license": "MIT",
"scripts": {
"eslint": "eslint --ignore-path .gitignore .",
"pretest": "npm run eslint",
"lint": "prettier --check . && npm run eslint",
"format": "prettier --write .",
"pretest": "npm run lint",
"test": "c8 --reporter=text --reporter=text-summary --reporter=lcovonly --reporter=cobertura node --test test/*.spec.js",
"dev": "run-s test start",
"start": "node server"
Expand All @@ -39,6 +41,7 @@
"eslint-plugin-unicorn": "49.0.0",
"got": "13.0.0",
"hash-to-port": "1.2.0",
"npm-run-all": "4.1.5"
"npm-run-all": "4.1.5",
"prettier": "3.0.3"
}
}
Loading

0 comments on commit cc7cbaf

Please sign in to comment.