Skip to content

Commit

Permalink
Deploy to Cloudflare Pages (#208)
Browse files Browse the repository at this point in the history
* Build on Cloudflare Pages

* Use Node 22 LTS

* Use Node 20.x

* Remove engine specification

* Use engine specification

* Try and nvmrc instead

* Assign vars in wrangler.toml
  • Loading branch information
UpliftMacaw authored Nov 13, 2024
1 parent 24312a0 commit 5450eb2
Show file tree
Hide file tree
Showing 7 changed files with 6,364 additions and 1,857 deletions.
3 changes: 3 additions & 0 deletions wally-registry-frontend/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -38,3 +38,6 @@ yarn-error.log*
# typescript
*.tsbuildinfo
next-env.d.ts

# cloudflare
.wrangler/
1 change: 1 addition & 0 deletions wally-registry-frontend/.nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
v20
5 changes: 5 additions & 0 deletions wally-registry-frontend/next.config.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import createMDX from "@next/mdx"
import type { NextConfig } from "next"
import { setupDevPlatform } from '@cloudflare/next-on-pages/next-dev';

const nextConfig: NextConfig = {
pageExtensions: ["js", "jsx", "md", "mdx", "ts", "tsx"],
Expand All @@ -12,4 +13,8 @@ const withMDX = createMDX({
// Add markdown plugins here, as desired
})

if (process.env.NODE_ENV === 'development') {
await setupDevPlatform();
}

export default withMDX(nextConfig)
Loading

0 comments on commit 5450eb2

Please sign in to comment.