-
Notifications
You must be signed in to change notification settings - Fork 1
/
next.config.mjs
41 lines (37 loc) · 984 Bytes
/
next.config.mjs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
import { withFaust, getWpHostname } from '@faustwp/core';
import withMarkdoc from '@markdoc/next.js'
import withSearch from './markdoc/search.mjs'
import { withAtlasConfig } from "@wpengine/atlas-next"
const getHeaders = async () => {
return [
{
source: "/:path*",
headers: [
{
key: "Content-Security-Policy",
value: "frame-ancestors 'self' *.wpgraphql.com",
},
],
},
];
}
const nextConfig = {
reactStrictMode: true,
pageExtensions: ['js', 'jsx', 'ts', 'tsx', 'mdx'],
experimental: {
scrollRestoration: true,
},
trailingSlash: true,
images: {
domains: [ getWpHostname() ],
},
headers: async () => await getHeaders(),
};
export default withAtlasConfig(
withFaust(
withSearch(
withMarkdoc({
schemaPath: './src/markdoc'
})( nextConfig )
)
));