Skip to content

Commit 74e34cb

Browse files
committed
fix: make other projects build as well
1 parent 4e550d9 commit 74e34cb

6 files changed

Lines changed: 72 additions & 81 deletions

File tree

apps/next-blog/project.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
"defaultConfiguration": "production",
1111
"options": {
1212
"root": "apps/next-blog",
13-
"outputPath": "dist/apps/next-blog"
13+
"outputPath": "apps/next-blog/.next"
1414
},
1515
"configurations": {
1616
"development": {
@@ -22,6 +22,7 @@
2222

2323
"build": {
2424
"executor": "nx:run-commands",
25+
"outputs": ["apps/next-blog/.next"],
2526
"options": {
2627
"commands": [
2728
"next build apps/next-blog && mv apps/next-blog/.next/static apps/next-blog/.next/standalone/apps/next-blog/.next && cp -r apps/next-blog/public apps/next-blog/.next/standalone/apps/next-blog/.next"

apps/og/project.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,10 @@
66
"targets": {
77
"build": {
88
"executor": "nx:run-commands",
9+
"outputs": ["apps/og/.next"],
910
"options": {
1011
"commands": [
11-
"next build apps/og",
12-
"mv apps/og/.next/static apps/og/.next/standalone/apps/og/.next",
13-
"cp -r apps/og/public apps/og/.next/standalone/apps/og/.next"
12+
"next build apps/og && mv apps/og/.next/static apps/og/.next/standalone/apps/og/.next && cp -r apps/og/public apps/og/.next/standalone/apps/og/.next"
1413
],
1514
"outputPath": "apps/og/.next"
1615
}

apps/peer-review/next.config.mjs

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,10 @@
44
* @type {import('next').NextConfig}
55
*/
66
const config = {
7-
images: {
8-
domains: ['cote.azureedge.net'],
9-
},
10-
}
7+
images: {
8+
domains: ["cote.azureedge.net"],
9+
},
10+
output: "standalone",
11+
};
1112

12-
export default config
13+
export default config;

apps/positions/next.config.js

Lines changed: 12 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,21 @@
11
//@ts-check
22

33
// eslint-disable-next-line @typescript-eslint/no-var-requires
4-
const { withNx } = require('@nx/next/plugins/with-nx')
4+
const { withNx } = require("@nx/next/plugins/with-nx");
55

66
/**
77
* @type {import('@nx/next/plugins/with-nx').WithNxOptions}
88
**/
99
const nextConfig = {
10-
nx: {
11-
// Set this to true if you would like to to use SVGR
12-
// See: https://github.com/gregberge/svgr
13-
svgr: false,
14-
},
15-
images: {
16-
domains: ['images.unsplash.com', 'cote.azureedge.net'],
17-
},
18-
experimental: {
19-
newNextLinkBehavior: true,
20-
},
21-
}
10+
nx: {
11+
// Set this to true if you would like to to use SVGR
12+
// See: https://github.com/gregberge/svgr
13+
svgr: false,
14+
},
15+
images: {
16+
domains: ["images.unsplash.com", "cote.azureedge.net"],
17+
},
18+
output: "standalone",
19+
};
2220

23-
module.exports = withNx(nextConfig)
21+
module.exports = withNx(nextConfig);

apps/positions/pages/_app.tsx

Lines changed: 45 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -1,62 +1,60 @@
1-
import { AppProps } from 'next/app'
2-
import Head from 'next/head'
3-
import { Analytics } from '@vercel/analytics/react'
4-
import '../styles.css'
5-
import { DefaultSeo } from 'next-seo'
6-
import { SITE } from '../config'
7-
import Script from 'next/script'
1+
import { Analytics } from "@vercel/analytics/react";
2+
import type { AppProps } from "next/app";
3+
import Head from "next/head";
4+
import "../styles.css";
85

9-
import { Overpass, Open_Sans } from 'next/font/google'
6+
import { Open_Sans, Overpass } from "next/font/google";
7+
import Script from "next/script";
8+
import { DefaultSeo } from "next-seo";
9+
import { SITE } from "../config";
1010

1111
const overpass = Overpass({
12-
subsets: ['latin'],
13-
variable: '--font-overpass',
14-
})
12+
subsets: ["latin"],
13+
variable: "--font-overpass",
14+
});
1515

1616
const open_sans = Open_Sans({
17-
subsets: ['latin'],
18-
variable: '--font-open-sans',
19-
})
17+
subsets: ["latin"],
18+
variable: "--font-open-sans",
19+
});
2020

2121
function CustomApp({ Component, pageProps }: AppProps) {
22-
return (
23-
<>
24-
<style jsx global>{`
22+
return (
23+
<>
24+
<style jsx global>{`
2525
:root {
2626
--font-open-sans: ${open_sans.style.fontFamily}, system-ui, sans-serif;
2727
--font-overpass: ${overpass.style.fontFamily}, system-ui, sans-serif;
2828
}
2929
`}</style>
3030

31-
<DefaultSeo
32-
openGraph={{
33-
type: 'website',
34-
locale: 'en_US',
35-
url: SITE.origin,
36-
site_name: SITE.name,
37-
description: SITE.description,
38-
images: [
39-
{
40-
url: 'https://og.trialanderror.org/api/og/jote?name=Open Positions',
41-
},
42-
],
43-
}}
44-
twitter={{
45-
handle: '@jtrialerror',
46-
site: '@jtrialerror',
47-
cardType: 'summary_large_image',
48-
}}
49-
/>
50-
<Component {...pageProps} />
51-
<Analytics />
52-
<Script
53-
strategy="afterInteractive"
54-
data-domain="trialanderror.org"
55-
src="/stats/js/script"
56-
data-api="/stats/api/event"
57-
/>
58-
</>
59-
)
31+
<DefaultSeo
32+
openGraph={{
33+
type: "website",
34+
locale: "en_US",
35+
url: SITE.origin,
36+
site_name: SITE.name,
37+
description: SITE.description,
38+
images: [
39+
{
40+
url: "https://og.trialanderror.org/api/og/jote?name=Open Positions",
41+
},
42+
],
43+
}}
44+
twitter={{
45+
handle: "@jtrialerror",
46+
site: "@jtrialerror",
47+
cardType: "summary_large_image",
48+
}}
49+
/>
50+
<Component {...pageProps} />
51+
<Script
52+
defer
53+
src="https://analytics.trialanderror.org/script.js"
54+
data-website-id="60d1573a-ec6c-43e7-88cb-2fdaae0701b1"
55+
/>
56+
</>
57+
);
6058
}
6159

62-
export default CustomApp
60+
export default CustomApp;

apps/positions/project.json

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,18 +5,12 @@
55
"projectType": "application",
66
"targets": {
77
"build": {
8-
"executor": "@nx/next:build",
9-
"outputs": ["{options.outputPath}"],
10-
"defaultConfiguration": "production",
8+
"executor": "nx:run-commands",
9+
"outputs": ["apps/positions/.next"],
1110
"options": {
12-
"root": "apps/positions",
13-
"outputPath": "dist/apps/positions"
14-
},
15-
"configurations": {
16-
"development": {
17-
"outputPath": "apps/positions"
18-
},
19-
"production": {}
11+
"commands": [
12+
"next build apps/positions && mv apps/positions/.next/static apps/positions/.next/standalone/apps/positions/.next && cp -r apps/positions/public apps/positions/.next/standalone/apps/positions/.next"
13+
]
2014
}
2115
},
2216
"serve": {

0 commit comments

Comments
 (0)