Skip to content

Commit 888eae1

Browse files
authored
cve: fix more broken deployments (#1341)
### Description Fixes remaining broken projects as follow-up on #1340 - [x] blob-sveltekit - [x] geolocation-script - [x] auth-with-ory - [x] nx-monorepo - [x] postgres-pgvector - [x] postgres-prisma - [x] microfrontends-docs - [x] microfrontends-marketing - [x] saas-microservices-dashboard - [x] solutions-microfrontends - [x] solutions-pagination-with-ssg - [x] solutions-script-component-strategies Still failing and may require more complex fixes (e.g. fixing the publish of the examples/ui package, will do in a follow-up: - [ ] feature-flag-hypertune - [ ] feature-flag-launchdarkly - [ ] redirects-bloom-filter - [ ] solutions-monorepo - [ ] solutions-nx-monorepo - [ ] solutions-testing ### Demo URL <!-- Provide a URL to a live deployment where we can test your PR. If a demo isn't possible feel free to omit this section. --> ### Type of Change - [ ] New Example - [ ] Example updates (Bug fixes, new features, etc.) - [ ] Other (changes to the codebase, but not to examples) ### New Example Checklist - [ ] 🛫 `npm run new-example` was used to create the example - [ ] 📚 The template wasn't used but I carefuly read the [Adding a new example](https://github.com/vercel/examples#adding-a-new-example) steps and implemented them in the example - [ ] 📱 Is it responsive? Are mobile and tablets considered?
1 parent cb2643e commit 888eae1

File tree

28 files changed

+3209
-1941
lines changed

28 files changed

+3209
-1941
lines changed

edge-middleware/geolocation-script/app/analytics.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ import { headers } from 'next/headers'
22
import { EU_COUNTRY_CODES } from './constants'
33
import Script from 'next/script'
44

5-
export default function Analytics() {
6-
const countryCode = headers().get('x-vercel-ip-country') || 'US'
5+
export default async function Analytics() {
6+
const countryCode = (await headers()).get('x-vercel-ip-country') || 'US'
77

88
if (EU_COUNTRY_CODES.includes(countryCode)) {
99
return (
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
/// <reference types="next" />
22
/// <reference types="next/image-types/global" />
3+
import "./.next/types/routes.d.ts";
34

45
// NOTE: This file should not be edited
56
// see https://nextjs.org/docs/app/api-reference/config/typescript for more information.

microfrontends/nextjs-multi-zones/apps/docs/next.config.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ const nextConfig: NextConfig = {
1010
typescript: {
1111
ignoreBuildErrors: true,
1212
},
13+
turbopack: {},
1314
};
1415

1516
export default withVercelToolbar()(
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
/// <reference types="next" />
22
/// <reference types="next/image-types/global" />
3+
import "./.next/types/routes.d.ts";
34

45
// NOTE: This file should not be edited
56
// see https://nextjs.org/docs/app/api-reference/config/typescript for more information.

microfrontends/nextjs-multi-zones/apps/marketing/next.config.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ const nextConfig: NextConfig = {
1010
typescript: {
1111
ignoreBuildErrors: true,
1212
},
13+
turbopack: {},
1314
};
1415

1516
export default withVercelToolbar()(
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
/// <reference types="next" />
22
/// <reference types="next/image-types/global" />
3+
import "./.next/types/routes.d.ts";
34

45
// NOTE: This file should not be edited
56
// see https://nextjs.org/docs/app/api-reference/config/typescript for more information.

microfrontends/saas-microservices/apps/dashboard/next.config.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import { withMicrofrontends } from "@vercel/microfrontends/next/config";
33

44
const nextConfig: NextConfig = {
55
/* config options here */
6+
turbopack: {},
67
};
78

89
export default withMicrofrontends(nextConfig);
Lines changed: 19 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,11 @@
11
{
22
"compilerOptions": {
33
"target": "ES2017",
4-
"lib": ["dom", "dom.iterable", "esnext"],
4+
"lib": [
5+
"dom",
6+
"dom.iterable",
7+
"esnext"
8+
],
59
"allowJs": true,
610
"skipLibCheck": true,
711
"strict": true,
@@ -11,17 +15,27 @@
1115
"moduleResolution": "bundler",
1216
"resolveJsonModule": true,
1317
"isolatedModules": true,
14-
"jsx": "preserve",
18+
"jsx": "react-jsx",
1519
"incremental": true,
1620
"plugins": [
1721
{
1822
"name": "next"
1923
}
2024
],
2125
"paths": {
22-
"@/*": ["./src/*"]
26+
"@/*": [
27+
"./src/*"
28+
]
2329
}
2430
},
25-
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"],
26-
"exclude": ["node_modules"]
31+
"include": [
32+
"next-env.d.ts",
33+
"**/*.ts",
34+
"**/*.tsx",
35+
".next/types/**/*.ts",
36+
".next/dev/types/**/*.ts"
37+
],
38+
"exclude": [
39+
"node_modules"
40+
]
2741
}

solutions/auth-with-ory/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
"@ory/integrations": "^0.2.1",
2020
"@ory/kratos-client": "^0.8.2-alpha.1",
2121
"@vercel/examples-ui": "^1.0.4",
22+
"axios": "^1.13.2",
2223
"next": "^16.0.10",
2324
"react": "^19.2.1",
2425
"react-dom": "^19.2.1"
Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,14 @@
11
// @ory/integrations offers a package for integrating with NextJS.
2-
import { config, createApiHandler } from '@ory/integrations/next-edge'
2+
import { createApiHandler } from '@ory/integrations/next-edge'
33

44
// We need to export the config.
5-
export { config }
5+
export const config = {
6+
api: {
7+
bodyParser: false,
8+
},
9+
}
610

711
// And create the Ory Cloud API "bridge".
812
export default createApiHandler({
9-
fallbackToPlayground: true
13+
fallbackToPlayground: true,
1014
})

0 commit comments

Comments
 (0)