Skip to content

Commit e6a3fab

Browse files
Merge pull request #902 from IgorKowalczyk/v5
Refactor project to replace Preact with Vue
2 parents 12de730 + 0ede8e2 commit e6a3fab

19 files changed

Lines changed: 1804 additions & 1268 deletions

.github/workflows/deploy.yml

Lines changed: 33 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -1,44 +1,36 @@
11
name: Deploy
2-
on:
3-
push:
4-
branches: main
5-
pull_request:
6-
branches: main
72

8-
jobs:
9-
deploy:
10-
name: Deploy
11-
runs-on: ubuntu-latest
12-
13-
permissions:
14-
id-token: write # Needed for auth with Deno Deploy
15-
contents: read # Needed to clone the repository
16-
17-
steps:
18-
- name: Clone repository
19-
uses: actions/checkout@v4
20-
21-
- name: Install Deno
22-
uses: denoland/setup-deno@v2
23-
with:
24-
deno-version: v2.x
3+
on: [push, pull_request]
254

26-
- name: Install Node.js
27-
uses: actions/setup-node@v4
28-
with:
29-
node-version: lts/*
30-
31-
- name: Install step
32-
run: "npm install"
33-
34-
- name: Build step
35-
run: "npm run build"
36-
37-
- name: Upload to Deno Deploy
38-
uses: denoland/deployctl@v1
39-
with:
40-
project: "profile-views"
41-
entrypoint: "server/entry.mjs"
42-
root: "dist"
43-
44-
5+
jobs:
6+
deploy:
7+
name: Deploy
8+
runs-on: ubuntu-latest
9+
strategy:
10+
fail-fast: false
11+
matrix:
12+
node: ["lts/*"]
13+
permissions:
14+
id-token: write
15+
contents: read
16+
steps:
17+
- name: 🧱 Checkout repository
18+
uses: actions/checkout@v4
19+
- name: 🔩 Setup PNPM
20+
uses: pnpm/action-setup@v4
21+
with:
22+
standalone: true
23+
- name: 🔩 Setup Node ${{ matrix.node }}
24+
uses: actions/setup-node@v4
25+
with:
26+
node-version: ${{ matrix.node }}
27+
cache: "pnpm"
28+
- name: 🚀 Install dependencies
29+
run: pnpm install
30+
- name: 🚀 Build project
31+
run: pnpm run build
32+
- name: 🚀 Upload to Deno Deploy
33+
uses: denoland/deployctl@v1
34+
with:
35+
project: ${{ vars.DENO_DEPLOY_PROJECT }}
36+
entrypoint: dist/server/entry.mjs

.github/workflows/format-check.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,8 @@ jobs:
1414
- name: 🧱 Checkout repository
1515
uses: actions/checkout@v4
1616
- name: 🔩 Setup PNPM
17-
uses: pnpm/action-setup@v3
17+
uses: pnpm/action-setup@v4
1818
with:
19-
version: next-9
2019
standalone: true
2120
- name: 🔩 Setup Node ${{ matrix.node }}
2221
uses: actions/setup-node@v4

.github/workflows/lint.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,8 @@ jobs:
1414
- name: 🧱 Checkout repository
1515
uses: actions/checkout@v4
1616
- name: 🔩 Setup PNPM
17-
uses: pnpm/action-setup@v3
17+
uses: pnpm/action-setup@v4
1818
with:
19-
version: next-9
2019
standalone: true
2120
- name: 🔩 Setup Node ${{ matrix.node }}
2221
uses: actions/setup-node@v4

astro.config.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,20 @@
11
// https://astro.build/config
2-
import preact from "@astrojs/preact";
2+
import vue from "@astrojs/vue";
33
import deno from "@deno/astro-adapter";
44
import tailwindcss from "@tailwindcss/vite";
55
import { defineConfig } from "astro/config";
66
import compress from "astro-compressor";
77

88
// https://astro.build/config
99
export default defineConfig({
10-
output: "server",
1110
site: "https://views.igorkowalczyk.dev",
1211
redirects: {
1312
"/github": "https://github.com/igorkowalczyk/views",
1413
"/docs": "https://github.com/IgorKowalczyk/github-views?tab=readme-ov-file#-basic-usage",
1514
},
15+
output: "server",
1616
adapter: deno(),
17-
integrations: [preact({ compat: true }), compress()],
17+
integrations: [vue(), compress()],
1818
vite: {
1919
plugins: [tailwindcss()],
2020
},

deno.json

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"deploy": {
3+
"project": "profile-views",
4+
"exclude": ["**/node_modules"],
5+
"include": [],
6+
"entrypoint": "dist/server/entry.mjs"
7+
}
8+
}

eslint.config.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
11
import eslintConfig from "@igorkowalczyk/eslint-config";
22
import eslintPluginAstro from "eslint-plugin-astro";
3+
// import pluginVue from "eslint-plugin-vue";
34

45
export default [
56
// prettier
67
...eslintConfig.base,
78
...eslintConfig.node,
8-
...eslintConfig.typescript,
99
...eslintPluginAstro.configs["flat/recommended"],
10+
// ...pluginVue.configs["flat/recommended"],
11+
...eslintConfig.typescript,
1012
];

package.json

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -33,21 +33,22 @@
3333
},
3434
"homepage": "https://views.igorkowalczyk.dev/",
3535
"dependencies": {
36-
"@astrojs/preact": "4.0.5",
36+
"@astrojs/vue": "5.0.7",
3737
"@deno/astro-adapter": "0.3.0",
38-
"@tailwindcss/vite": "^4.0.11",
38+
"@tailwindcss/vite": "4.0.14",
3939
"@types/canvas-confetti": "1.9.0",
40-
"astro": "5.5.2",
40+
"@vueuse/core": "13.0.0",
41+
"astro": "5.5.3",
4142
"astro-compressor": "1.0.0",
4243
"badgen": "3.2.3",
4344
"canvas-confetti": "1.9.3",
4445
"class-variance-authority": "0.7.1",
4546
"clsx": "2.1.1",
46-
"postcss": "8.5.3",
47-
"preact": "10.26.4",
48-
"sharp": "0.33.5",
47+
"eslint-plugin-vue": "10.0.0",
48+
"lucide-vue-next": "0.483.0",
4949
"tailwind-merge": "3.0.2",
50-
"tailwindcss": "4.0.14"
50+
"tailwindcss": "4.0.14",
51+
"vue": "3.5.13"
5152
},
5253
"devDependencies": {
5354
"@igorkowalczyk/eslint-config": "3.0.7",
@@ -56,11 +57,8 @@
5657
"eslint": "9.22.0",
5758
"prettier": "3.5.3",
5859
"prettier-plugin-astro": "0.14.1",
59-
"prettier-plugin-tailwindcss": "0.6.11"
60-
},
61-
"overrides": {
62-
"react": "npm:@preact/compat@latest",
63-
"react-dom": "npm:@preact/compat@latest"
60+
"prettier-plugin-tailwindcss": "0.6.11",
61+
"typescript": "5.8.2"
6462
},
6563
"packageManager": "pnpm@10.6.4",
6664
"pnpm": {

0 commit comments

Comments
 (0)