Skip to content

Commit 0da802b

Browse files
Merge pull request #354 from community-scripts/bugfixing_bumps
Add TypeScript Runtime Support and add Prisma 7 Compatibility
2 parents 7833d5d + 5bc3933 commit 0da802b

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

53 files changed

+9546
-4969
lines changed

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@
1616
db.sqlite
1717
data/settings.db
1818

19+
# prisma generated client
20+
/prisma/generated/
21+
1922
# ssh keys (sensitive)
2023
data/ssh-keys/
2124

eslint.config.js

Lines changed: 15 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,23 @@
1+
import eslintPluginNext from "@next/eslint-plugin-next";
12
import tseslint from "typescript-eslint";
2-
import { createRequire } from "module";
3-
import { fileURLToPath } from "url";
4-
import path from "path";
5-
6-
const __filename = fileURLToPath(import.meta.url);
7-
const __dirname = path.dirname(__filename);
8-
const require = createRequire(import.meta.url);
9-
10-
// Import Next.js config directly (it's already in flat config format)
11-
const nextConfig = require("eslint-config-next/core-web-vitals");
3+
import reactPlugin from "eslint-plugin-react";
4+
import reactHooksPlugin from "eslint-plugin-react-hooks";
125

136
export default tseslint.config(
147
{
15-
ignores: [".next", "node_modules"],
8+
ignores: [".next", "next-env.d.ts", "postcss.config.js", "prettier.config.js"],
9+
},
10+
{
11+
plugins: {
12+
"@next/next": eslintPluginNext,
13+
"react": reactPlugin,
14+
"react-hooks": reactHooksPlugin,
15+
},
16+
rules: {
17+
...eslintPluginNext.configs.recommended.rules,
18+
...eslintPluginNext.configs["core-web-vitals"].rules,
19+
},
1620
},
17-
...nextConfig,
1821
{
1922
files: ["**/*.ts", "**/*.tsx"],
2023
extends: [

next.config.js

Lines changed: 14 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -18,30 +18,20 @@ const config = {
1818
},
1919
],
2020
},
21-
// Allow cross-origin requests from local network ranges
22-
allowedDevOrigins: [
23-
'http://localhost:3000',
24-
'http://127.0.0.1:3000',
25-
'http://[::1]:3000',
26-
'http://10.*',
27-
'http://172.16.*',
28-
'http://172.17.*',
29-
'http://172.18.*',
30-
'http://172.19.*',
31-
'http://172.20.*',
32-
'http://172.21.*',
33-
'http://172.22.*',
34-
'http://172.23.*',
35-
'http://172.24.*',
36-
'http://172.25.*',
37-
'http://172.26.*',
38-
'http://172.27.*',
39-
'http://172.28.*',
40-
'http://172.29.*',
41-
'http://172.30.*',
42-
'http://172.31.*',
43-
'http://192.168.*',
44-
],
21+
// Allow cross-origin requests from local network in dev mode
22+
// Note: In Next.js 16, we disable this check entirely for dev
23+
async headers() {
24+
return [
25+
{
26+
source: '/:path*',
27+
headers: [
28+
{ key: 'Access-Control-Allow-Origin', value: '*' },
29+
{ key: 'Access-Control-Allow-Methods', value: 'GET,POST,PUT,DELETE,OPTIONS' },
30+
{ key: 'Access-Control-Allow-Headers', value: 'Content-Type, Authorization' },
31+
],
32+
},
33+
];
34+
},
4535

4636
turbopack: {
4737
// Disable Turbopack and use Webpack instead for compatibility

0 commit comments

Comments
 (0)