From 14a3619a049dacdb52258fdfaed399c4b9e618d4 Mon Sep 17 00:00:00 2001 From: Eli <88557639+lishaduck@users.noreply.github.com> Date: Wed, 8 May 2024 21:08:49 -0500 Subject: [PATCH 1/5] ci: lighthouse the calculator --- .github/workflows/deno.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/deno.yaml b/.github/workflows/deno.yaml index 68978694..4cd88eb2 100644 --- a/.github/workflows/deno.yaml +++ b/.github/workflows/deno.yaml @@ -77,4 +77,5 @@ jobs: ${{ steps.deno-deploy.outputs.url }}about/ ${{ steps.deno-deploy.outputs.url }}solutions/solar/ ${{ steps.deno-deploy.outputs.url }}solutions/geothermal/environment/ + ${{ steps.deno-deploy.outputs.url }}calculator/ uploadArtifacts: true From b9ab2a1f34244f93b06c16999dca39821a4af1de Mon Sep 17 00:00:00 2001 From: Eli <88557639+lishaduck@users.noreply.github.com> Date: Wed, 8 May 2024 21:20:22 -0500 Subject: [PATCH 2/5] ci: add lhci assertions --- .github/workflows/deno.yaml | 1 + lighthouserc.json | 8 ++++++++ 2 files changed, 9 insertions(+) create mode 100644 lighthouserc.json diff --git a/.github/workflows/deno.yaml b/.github/workflows/deno.yaml index 4cd88eb2..a32789f4 100644 --- a/.github/workflows/deno.yaml +++ b/.github/workflows/deno.yaml @@ -79,3 +79,4 @@ jobs: ${{ steps.deno-deploy.outputs.url }}solutions/geothermal/environment/ ${{ steps.deno-deploy.outputs.url }}calculator/ uploadArtifacts: true + configPath: lighthouserc.json diff --git a/lighthouserc.json b/lighthouserc.json new file mode 100644 index 00000000..faf4996a --- /dev/null +++ b/lighthouserc.json @@ -0,0 +1,8 @@ +{ + "$schema": "https://gist.githubusercontent.com/jfhr/181123d7acc87ea329be3700d9c37594/raw/9dafefb638f8ff0660930cc48debefa1dfcd87ca/lighthouserc.schema.json", + "ci": { + "assert": { + "preset": "lighthouse:recommended" + } + } +} From 35f28114636840690c7bcbe9b256337c9cad466f Mon Sep 17 00:00:00 2001 From: Eli <88557639+lishaduck@users.noreply.github.com> Date: Thu, 9 May 2024 09:14:46 -0500 Subject: [PATCH 3/5] chore: better seo --- src/static/robots.txt | 2 ++ src/static/sitemap.xml | 45 ++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 47 insertions(+) create mode 100644 src/static/robots.txt create mode 100644 src/static/sitemap.xml diff --git a/src/static/robots.txt b/src/static/robots.txt new file mode 100644 index 00000000..eb053628 --- /dev/null +++ b/src/static/robots.txt @@ -0,0 +1,2 @@ +User-agent: * +Disallow: diff --git a/src/static/sitemap.xml b/src/static/sitemap.xml new file mode 100644 index 00000000..4ca6ad60 --- /dev/null +++ b/src/static/sitemap.xml @@ -0,0 +1,45 @@ + + + + https://why-switch.deno.dev/ + 2024-05-08 + weekly + 1.0 + + + https://why-switch.deno.dev/about/ + 2024-05-08 + weekly + 0.8 + + + https://why-switch.deno.dev/calculator/ + 2024-05-08 + weekly + 0.8 + + + https://why-switch.deno.dev/solutions/solar/ + 2024-05-08 + weekly + 0.5 + + + https://why-switch.deno.dev/solutions/geothermal/ + 2024-05-08 + weekly + 0.5 + + + https://why-switch.deno.dev/solutions/recycling/ + 2024-05-08 + weekly + 0.5 + + + https://why-switch.deno.dev/solutions/other/ + 2024-05-08 + weekly + 0.5 + + From 5c2debee692fb2b58afa8204c2cfee09cb2043a9 Mon Sep 17 00:00:00 2001 From: Eli <88557639+lishaduck@users.noreply.github.com> Date: Thu, 9 May 2024 09:20:26 -0500 Subject: [PATCH 4/5] fix: ignore crawlability --- lighthouserc.json | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lighthouserc.json b/lighthouserc.json index faf4996a..d587c7dd 100644 --- a/lighthouserc.json +++ b/lighthouserc.json @@ -2,7 +2,10 @@ "$schema": "https://gist.githubusercontent.com/jfhr/181123d7acc87ea329be3700d9c37594/raw/9dafefb638f8ff0660930cc48debefa1dfcd87ca/lighthouserc.schema.json", "ci": { "assert": { - "preset": "lighthouse:recommended" + "preset": "lighthouse:recommended", + "assertions": { + "is-crawlable": ["off"] + } } } } From 54fef748a69fb3368bf2321f9d003a2e62d39231 Mon Sep 17 00:00:00 2001 From: Eli <88557639+lishaduck@users.noreply.github.com> Date: Sun, 19 May 2024 18:19:32 -0500 Subject: [PATCH 5/5] ci: update lhci action config Signed-off-by: Eli <88557639+lishaduck@users.noreply.github.com> --- .github/workflows/deno.yaml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/deno.yaml b/.github/workflows/deno.yaml index a32789f4..fad90fb4 100644 --- a/.github/workflows/deno.yaml +++ b/.github/workflows/deno.yaml @@ -71,6 +71,8 @@ jobs: deno.json - name: 🔦 Lighthouse uses: treosh/lighthouse-ci-action@1b0e7c33270fbba31a18a0fbb1de7cc5256b6d39 # 11.4.0 + env: + LHCI_GITHUB_APP_TOKEN: ${{ secrets.LHCI_GITHUB_APP_TOKEN }} with: urls: | ${{ steps.deno-deploy.outputs.url }} @@ -79,4 +81,5 @@ jobs: ${{ steps.deno-deploy.outputs.url }}solutions/geothermal/environment/ ${{ steps.deno-deploy.outputs.url }}calculator/ uploadArtifacts: true + temporaryPublicStorage: true configPath: lighthouserc.json