Skip to content

Commit

Permalink
fix(demo): more tweaks to get files
Browse files Browse the repository at this point in the history
  • Loading branch information
tobua committed Feb 16, 2024
1 parent c5773ab commit 24fd565
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
2 changes: 1 addition & 1 deletion demo/api/serverless/[lang].ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { Language } from 'epic-language'
import { translate } from 'epic-language/function'
import { promises as fs } from 'fs'
import { it } from 'avait'
import englishSheetImport from './en.json' assert { type: 'json' }
import englishSheetImport from './en.json' with { type: 'json' }

export default async function handler(request: VercelRequest, response: VercelResponse) {
console.log(process.cwd(), new URL('./en.json', import.meta.url), englishSheetImport)
Expand Down
1 change: 1 addition & 0 deletions demo/api/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,6 @@
"moduleResolution": "NodeNext",
"module": "NodeNext",
"resolveJsonModule": true,
"esModuleInterop": true,
},
}
8 changes: 8 additions & 0 deletions demo/api/vercel.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"$schema": "https://openapi.vercel.sh/vercel.json",
"functions": {
"api/static/edge/[lang].ts": {
"includeFiles": "./api/static/edge/*.json"
}
}
}

0 comments on commit 24fd565

Please sign in to comment.