Skip to content

Commit

Permalink
Getting ready for deploy
Browse files Browse the repository at this point in the history
  • Loading branch information
Neo-Zhixing committed Nov 4, 2023
1 parent 026c980 commit 7c46981
Show file tree
Hide file tree
Showing 6 changed files with 49 additions and 2 deletions.
35 changes: 35 additions & 0 deletions .github/workflows/cloudflare.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: cloudflare

on:
push:
branches:
- master
pull_request:
branches:
- master

jobs:
ci:
runs-on: ubuntu-latest

steps:
- uses: actions/setup-node@v1
with:
node-version: 20
cache: 'npm'

- name: Checkout
uses: actions/checkout@master

- name: Install Dependencies
run: npm install

- name: Build
run: npm run build
env:
NITRO_PRESET: cloudflare_module

- name: Publish to Cloudflare
uses: cloudflare/wrangler-action@v3
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
5 changes: 5 additions & 0 deletions nuxt.config.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
export default defineNuxtConfig({
// https://github.com/nuxt-themes/docus
extends: '@nuxt-themes/docus',
nitro: {
prerender: {
crawlLinks: true,
}
},
devtools: { enabled: true },

modules: [
Expand Down
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"@nuxtjs/plausible": "^0.2.3",
"@types/node": "^20.8.2",
"eslint": "^8.50.0",
"nuxt": "^3.7.4"
"nuxt": "^3.8.0"
},
"overrides": {
"@nuxt/content": "npm:@nuxt/content-edge@latest"
Expand Down
7 changes: 7 additions & 0 deletions wrangler.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
name = "playground"
main = "./.output/server/index.mjs"
workers_dev = true
compatibility_date = "2022-09-10"

[site]
bucket = ".output/public"

0 comments on commit 7c46981

Please sign in to comment.