Skip to content

Commit

Permalink
refactor: switch from react to preact
Browse files Browse the repository at this point in the history
  • Loading branch information
StarHeartHunt committed Jun 21, 2024
1 parent e7d7b4e commit bed3549
Show file tree
Hide file tree
Showing 4 changed files with 199 additions and 288 deletions.
4 changes: 2 additions & 2 deletions astro.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import remarkToc from "remark-toc";
import Icons from "unplugin-icons/vite";
import { fileURLToPath } from "url";
import { remarkReadingTime } from "./src/utils/frontmatter";

import preact from "@astrojs/preact";
const __filename = fileURLToPath(import.meta.url);
const __dirname = dirname(__filename);

Expand Down Expand Up @@ -105,7 +105,7 @@ export default defineConfig({
mdx(),
sitemap(),
tailwind(),
react(),
preact({ compat: true }),
compress({
CSS: true,
HTML: true,
Expand Down
5 changes: 4 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
"devDependencies": {
"@astrojs/markdown-remark": "^5.1.0",
"@astrojs/mdx": "^3.1.0",
"@astrojs/react": "^3.5.0",
"@astrojs/rss": "^4.0.6",
"@astrojs/sitemap": "^3.1.5",
"@astrojs/tailwind": "^5.1.0",
Expand Down Expand Up @@ -56,5 +55,9 @@
"tailwindcss": "^3.4.4",
"typescript": "^5.4.5",
"unplugin-icons": "^0.19.0"
},
"dependencies": {
"@astrojs/preact": "^3.5.0",
"preact": "^10.22.0"
}
}
Loading

0 comments on commit bed3549

Please sign in to comment.