Skip to content

Commit

Permalink
Add cloudflare dependencies and scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
Safi1012 committed Apr 1, 2024
1 parent cbcf729 commit 94ccec0
Show file tree
Hide file tree
Showing 3 changed files with 512 additions and 10 deletions.
10 changes: 9 additions & 1 deletion astro.config.mjs
Original file line number Diff line number Diff line change
@@ -1,4 +1,12 @@
import { defineConfig } from "astro/config";
import cloudflare from "@astrojs/cloudflare";

// https://astro.build/config
export default defineConfig({});
export default defineConfig({
output: "server",
adapter: cloudflare({
platformProxy: {
enabled: true
}
})
});
9 changes: 7 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,23 @@
"dev": "astro dev",
"start": "astro dev",
"build": "astro check && astro build",
"preview": "astro preview",
"preview": "astro build && wrangler pages dev ./dist",
"astro": "astro",
"deploy": "astro build && wrangler pages deploy ./dist",
"build-cf-types": "wrangler types",
"prettier": "prettier --write .",
"prettier:check": "prettier --check ."
},
"dependencies": {
"@astrojs/check": "^0.5.10",
"@astrojs/cloudflare": "^10.0.2",
"astro": "^4.5.9",
"typescript": "^5.4.3"
},
"devDependencies": {
"prettier": "^3.2.5",
"prettier-plugin-astro": "^0.13.0"
"prettier-plugin-astro": "^0.13.0",
"@cloudflare/workers-types": "^4.20240329.0",
"wrangler": "^3.41.0"
}
}
Loading

0 comments on commit 94ccec0

Please sign in to comment.