Skip to content
This repository has been archived by the owner on Dec 12, 2024. It is now read-only.

Commit

Permalink
fix: nextjs not starting due to dynamic list
Browse files Browse the repository at this point in the history
  • Loading branch information
ijsKoud committed May 3, 2023
1 parent 7e6737c commit 4f05a34
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 5 deletions.
18 changes: 14 additions & 4 deletions apps/web/next.config.mjs
Original file line number Diff line number Diff line change
@@ -1,12 +1,22 @@
import { readdirSync } from "node:fs";
import { join } from "node:path";
// import { readdirSync } from "node:fs";
// import { join } from "node:path";

const transpilePackages = readdirSync(join(process.cwd(), "..", "..", "packages")).map((pkg) => `@paperplane/${pkg}`);
// const transpilePackages = readdirSync(join(process.cwd(), "..", "..", "packages")).map((pkg) => `@paperplane/${pkg}`);

/** @type {import('next').NextConfig} */
const config = {
reactStrictMode: false,
transpilePackages
transpilePackages: [
"@paperplane/buttons",
"@paperplane/forms",
"@paperplane/logo",
"@paperplane/markdown",
"@paperplane/modal",
"@paperplane/navbar",
"@paperplane/swr",
"@paperplane/ui",
"@paperplane/utils"
]
};

export default config;
2 changes: 1 addition & 1 deletion apps/web/tsconfig.eslint.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"extends": "./tsconfig.json",
"include": ["test", "src"]
"include": ["test", "src", "next.config.mjs"]
}

0 comments on commit 4f05a34

Please sign in to comment.