From 0aa105a4b92badd55076c1db70b4711eec08793b Mon Sep 17 00:00:00 2001 From: "plebeius.eth" Date: Sat, 16 Sep 2023 21:19:56 +0200 Subject: [PATCH] add prettier --- package.json | 4 +++- prettier.config.js | 6 ++++++ yarn.lock | 5 +++++ 3 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 prettier.config.js diff --git a/package.json b/package.json index 34216ba0..7ba97964 100644 --- a/package.json +++ b/package.json @@ -63,7 +63,8 @@ "electron:before": "yarn electron:before:download-ipfs && yarn electron:before:delete-data", "electron:before:download-ipfs": "node electron/downloadIpfs", "electron:before:delete-data": "rimraf .plebbit", - "android:build:icons": "cordova-res android --skip-config --copy --resources /tmp/plebbit-react-android-icons --icon-source ./android/icons/icon.png --splash-source ./android/icons/splash.png --icon-foreground-source ./android/icons/icon-foreground.png --icon-background-source '#ffffee'" + "android:build:icons": "cordova-res android --skip-config --copy --resources /tmp/plebbit-react-android-icons --icon-source ./android/icons/icon.png --splash-source ./android/icons/splash.png --icon-foreground-source ./android/icons/icon-foreground.png --icon-background-source '#ffffee'", + "prettier": "prettier src/**/*.{js,jsx} --write" }, "eslintConfig": { "extends": [ @@ -131,6 +132,7 @@ "decompress": "4.2.1", "electron": "19.1.8", "electron-builder": "23.0.9", + "prettier": "2.3.2", "source-map-explorer": "2.5.3", "typescript": "5.0.2", "wait-on": "7.0.1" diff --git a/prettier.config.js b/prettier.config.js new file mode 100644 index 00000000..c7f18629 --- /dev/null +++ b/prettier.config.js @@ -0,0 +1,6 @@ +module.exports = { + semi: false, + singleQuote: true, + printWidth: 170, + bracketSpacing: false, +} \ No newline at end of file diff --git a/yarn.lock b/yarn.lock index ce0deb66..1f18405b 100644 --- a/yarn.lock +++ b/yarn.lock @@ -12094,6 +12094,11 @@ prepend-http@^2.0.0: resolved "https://registry.yarnpkg.com/prepend-http/-/prepend-http-2.0.0.tgz#e92434bfa5ea8c19f41cdfd401d741a3c819d897" integrity sha512-ravE6m9Atw9Z/jjttRUZ+clIXogdghyZAuWJ3qEzjT+jI/dL1ifAqhZeC5VHzQp1MSt1+jxKkFNemj/iO7tVUA== +prettier@2.3.2: + version "2.3.2" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.3.2.tgz#ef280a05ec253712e486233db5c6f23441e7342d" + integrity sha512-lnJzDfJ66zkMy58OL5/NY5zp70S7Nz6KqcKkXYzn2tMVrNxvbqaBpg7H3qHaLxCJ5lNMsGuM8+ohS7cZrthdLQ== + pretty-bytes@^5.3.0, pretty-bytes@^5.4.1: version "5.6.0" resolved "https://registry.yarnpkg.com/pretty-bytes/-/pretty-bytes-5.6.0.tgz#356256f643804773c82f64723fe78c92c62beaeb"