From 9126f415ea9b2f2c9f45611bfe82bd6b52a7a9b0 Mon Sep 17 00:00:00 2001 From: Josh Lee Date: Sun, 12 Jun 2022 22:42:56 +0000 Subject: [PATCH] extract unrelated config --- CONTRIBUTING.md | 4 ++-- package.json | 4 +++- src/configs/config.svgo.cjs => svgo.config.js | 4 +--- 3 files changed, 6 insertions(+), 6 deletions(-) rename src/configs/config.svgo.cjs => svgo.config.js (89%) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index e372a6c0b..2de27d51e 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -190,8 +190,8 @@ In addition, the following style guidelines are recommended: In general, this style is not trying to exactly replicate highway shields as seen on signage. Instead, we are trying to extract the key stylistic elements so that the graphics are recognizable as simplifications of their real-world counterparts. Here are some examples of Americana's simplified shields for small-size readability: -| Network | Real-world Shield | Americana Representation | -| ---------------------- | ---------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------- | +| Network | Real-world Shield | Americana Representation | +| ---------------------- | ---------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------- | | NJ Turnpike | | | | Washington State Route | | | diff --git a/package.json b/package.json index 2a0d63835..5790ab9d1 100644 --- a/package.json +++ b/package.json @@ -9,7 +9,9 @@ }, "scripts": { "config": "cp src/configs/config.maptiler.js src/config.js", - "code_format": "npx prettier --write . && npx svgo -f icons/ --config src/configs/config.svgo.cjs", + "code_format": "run-s code_format:prettier code_format:svgo", + "code_format:prettier": "prettier --write .", + "code_format:svgo": "svgo -f icons/", "clean": "rm -rf dist .parcel-cache", "presprites": "rm -rf dist/sprites", "sprites": "node scripts/sprites.js", diff --git a/src/configs/config.svgo.cjs b/svgo.config.js similarity index 89% rename from src/configs/config.svgo.cjs rename to svgo.config.js index e3123c28c..1fbb92629 100644 --- a/src/configs/config.svgo.cjs +++ b/svgo.config.js @@ -1,6 +1,4 @@ -"use strict"; - -module.exports = { +export default { multipass: true, js2svg: { indent: 1,