create-fumadocs-app 15.7.10 → 15.7.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chunk-G2RYUJKU.js → chunk-QR7OIAKE.js} +41 -25
- package/dist/create-app.d.ts +6 -3
- package/dist/create-app.js +1 -1
- package/dist/index.js +33 -12
- package/package.json +4 -4
- package/template/+next+biome/biome.json +34 -0
- package/template/+next+content-collections/content-collections.ts +4 -4
- package/template/+next+content-collections/tsconfig.json +1 -1
- package/template/+next+eslint/eslint.config.mjs +26 -0
- package/template/react-router/package.json +1 -0
- package/template/tanstack-start/package.json +1 -0
- package/template/waku/package.json +1 -0
- package/template/waku/src/pages/(home)/_layout.tsx +0 -6
- package/template/waku/src/pages/_layout.tsx +0 -6
- package/template/waku/src/pages/docs/_layout.tsx +0 -6
- package/template/+next+eslint/.eslintrc.json +0 -3
|
@@ -59,7 +59,7 @@ async function tryGitInit(cwd2) {
|
|
|
59
59
|
}
|
|
60
60
|
|
|
61
61
|
// src/versions.js
|
|
62
|
-
var versions = { "fumadocs-core": "15.7.
|
|
62
|
+
var versions = { "fumadocs-core": "15.7.11", "fumadocs-ui": "15.7.11", "fumadocs-mdx": "11.9.0", "@fumadocs/mdx-remote": "1.4.0", "@fumadocs/content-collections": "1.2.2" };
|
|
63
63
|
|
|
64
64
|
// ../create-app-versions/package.json
|
|
65
65
|
var package_default = {
|
|
@@ -69,6 +69,7 @@ var package_default = {
|
|
|
69
69
|
description: "Used to track dependency versions in create-fumadocs-app",
|
|
70
70
|
license: "MIT",
|
|
71
71
|
dependencies: {
|
|
72
|
+
"@biomejs/biome": "^2.2.3",
|
|
72
73
|
"@content-collections/core": "^0.11.1",
|
|
73
74
|
"@content-collections/mdx": "^0.2.2",
|
|
74
75
|
"@content-collections/next": "^0.2.7",
|
|
@@ -77,8 +78,8 @@ var package_default = {
|
|
|
77
78
|
"@react-router/serve": "^7.8.2",
|
|
78
79
|
"@tailwindcss/postcss": "^4.1.13",
|
|
79
80
|
"@tailwindcss/vite": "^4.1.13",
|
|
80
|
-
"@tanstack/react-router": "^1.131.
|
|
81
|
-
"@tanstack/react-start": "^1.131.
|
|
81
|
+
"@tanstack/react-router": "^1.131.36",
|
|
82
|
+
"@tanstack/react-start": "^1.131.36",
|
|
82
83
|
"@types/mdx": "^2.0.13",
|
|
83
84
|
"@types/node": "24.3.1",
|
|
84
85
|
"@types/react": "^19.1.12",
|
|
@@ -94,10 +95,10 @@ var package_default = {
|
|
|
94
95
|
"react-router-devtools": "^5.1.3",
|
|
95
96
|
shiki: "^3.12.2",
|
|
96
97
|
tailwindcss: "^4.1.13",
|
|
97
|
-
tinyglobby: "^0.2.
|
|
98
|
+
tinyglobby: "^0.2.15",
|
|
98
99
|
typescript: "^5.9.2",
|
|
99
100
|
vinxi: "^0.5.8",
|
|
100
|
-
vite: "^7.1.
|
|
101
|
+
vite: "^7.1.5",
|
|
101
102
|
"vite-tsconfig-paths": "^5.1.4"
|
|
102
103
|
}
|
|
103
104
|
};
|
|
@@ -182,13 +183,13 @@ async function create(options) {
|
|
|
182
183
|
);
|
|
183
184
|
log("Configured Tailwind CSS");
|
|
184
185
|
}
|
|
185
|
-
if (options.
|
|
186
|
+
if (options.lint) {
|
|
186
187
|
await copy(
|
|
187
|
-
path.join(sourceDir, `template/+next
|
|
188
|
+
path.join(sourceDir, `template/+next+${options.lint}`),
|
|
188
189
|
dest,
|
|
189
190
|
defaultRename
|
|
190
191
|
);
|
|
191
|
-
log("Configured
|
|
192
|
+
log("Configured Linter");
|
|
192
193
|
}
|
|
193
194
|
if (options.useSrcDir) {
|
|
194
195
|
const tsconfigPath = path.join(dest, "tsconfig.json");
|
|
@@ -256,22 +257,33 @@ async function createNextPackageJson(projectName, options) {
|
|
|
256
257
|
build: "next build",
|
|
257
258
|
dev: "next dev --turbo",
|
|
258
259
|
start: "next start",
|
|
259
|
-
...options.template === "+next+fuma-docs-mdx"
|
|
260
|
+
...options.template === "+next+fuma-docs-mdx" && {
|
|
260
261
|
postinstall: "fumadocs-mdx"
|
|
261
|
-
}
|
|
262
|
+
},
|
|
263
|
+
...options.lint && {
|
|
264
|
+
eslint: {
|
|
265
|
+
lint: "eslint"
|
|
266
|
+
},
|
|
267
|
+
biome: { lint: "biome check", format: "biome format --write" }
|
|
268
|
+
}[options.lint]
|
|
262
269
|
},
|
|
263
270
|
dependencies: {
|
|
264
271
|
...pick(package_default.dependencies, ["next", "react", "react-dom"]),
|
|
265
272
|
...pick(versions, ["fumadocs-ui", "fumadocs-core"]),
|
|
266
|
-
...
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
273
|
+
...{
|
|
274
|
+
"+next+content-collections": {
|
|
275
|
+
...pick(package_default.dependencies, [
|
|
276
|
+
"@content-collections/mdx",
|
|
277
|
+
"@content-collections/core",
|
|
278
|
+
"@content-collections/next"
|
|
279
|
+
]),
|
|
280
|
+
...pick(versions, ["@fumadocs/content-collections"])
|
|
281
|
+
},
|
|
282
|
+
"+next+fuma-docs-mdx": pick(versions, ["fumadocs-mdx"]),
|
|
283
|
+
waku: null,
|
|
284
|
+
"tanstack-start": null,
|
|
285
|
+
"react-router": null
|
|
286
|
+
}[options.template]
|
|
275
287
|
},
|
|
276
288
|
devDependencies: {
|
|
277
289
|
...pick(package_default.dependencies, [
|
|
@@ -281,15 +293,19 @@ async function createNextPackageJson(projectName, options) {
|
|
|
281
293
|
"typescript",
|
|
282
294
|
"@types/mdx"
|
|
283
295
|
]),
|
|
284
|
-
...options.tailwindcss
|
|
296
|
+
...options.tailwindcss && pick(package_default.dependencies, [
|
|
285
297
|
"@tailwindcss/postcss",
|
|
286
298
|
"tailwindcss",
|
|
287
299
|
"postcss"
|
|
288
|
-
])
|
|
289
|
-
...options.
|
|
290
|
-
eslint:
|
|
291
|
-
|
|
292
|
-
|
|
300
|
+
]),
|
|
301
|
+
...options.lint && {
|
|
302
|
+
eslint: {
|
|
303
|
+
eslint: "^9",
|
|
304
|
+
"eslint-config-next": package_default.dependencies.next,
|
|
305
|
+
"@eslint/eslintrc": "^3"
|
|
306
|
+
},
|
|
307
|
+
biome: pick(package_default.dependencies, ["@biomejs/biome"])
|
|
308
|
+
}[options.lint]
|
|
293
309
|
}
|
|
294
310
|
};
|
|
295
311
|
}
|
package/dist/create-app.d.ts
CHANGED
|
@@ -23,11 +23,14 @@ interface Options {
|
|
|
23
23
|
*/
|
|
24
24
|
tailwindcss: boolean;
|
|
25
25
|
/**
|
|
26
|
-
*
|
|
27
|
-
*
|
|
28
|
-
* (Next.js only)
|
|
26
|
+
* @deprecated use `lint` instead.
|
|
29
27
|
*/
|
|
30
28
|
eslint?: boolean;
|
|
29
|
+
/**
|
|
30
|
+
* Configure Lint (Next.js Only)
|
|
31
|
+
* @defaultValue false
|
|
32
|
+
*/
|
|
33
|
+
lint?: 'eslint' | 'biome' | false;
|
|
31
34
|
installDeps?: boolean;
|
|
32
35
|
initializeGit?: boolean;
|
|
33
36
|
log?: (message: string) => void;
|
package/dist/create-app.js
CHANGED
package/dist/index.js
CHANGED
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
getPackageManager,
|
|
6
6
|
managers,
|
|
7
7
|
templates
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-QR7OIAKE.js";
|
|
9
9
|
|
|
10
10
|
// src/index.ts
|
|
11
11
|
import fs from "fs/promises";
|
|
@@ -28,6 +28,8 @@ program.option("--src", "(Next.js only) enable `src/` directory");
|
|
|
28
28
|
program.option("--no-src", "(Next.js only) disable `src/` directory");
|
|
29
29
|
program.option("--eslint", "(Next.js only) enable ESLint configuration");
|
|
30
30
|
program.option("--no-eslint", "(Next.js only) disable ESLint configuration");
|
|
31
|
+
program.option("--biome", "(Next.js only) enable Biome configuration");
|
|
32
|
+
program.option("--no-biome", "(Next.js only) disable Biome configuration");
|
|
31
33
|
program.option("--install", "Enable installing packages automatically");
|
|
32
34
|
program.option("--no-install", "Disable installing packages automatically");
|
|
33
35
|
program.option("--no-git", "Disable auto Git repository initialization");
|
|
@@ -94,20 +96,39 @@ async function main(config) {
|
|
|
94
96
|
]
|
|
95
97
|
});
|
|
96
98
|
},
|
|
97
|
-
src: (v) => {
|
|
98
|
-
if (!v.results.template?.startsWith("+next")) return;
|
|
99
|
-
if (config.src !== void 0) return
|
|
99
|
+
src: async (v) => {
|
|
100
|
+
if (!v.results.template?.startsWith("+next")) return false;
|
|
101
|
+
if (config.src !== void 0) return config.src;
|
|
100
102
|
return confirm({
|
|
101
103
|
message: "Use `/src` directory?",
|
|
102
104
|
initialValue: false
|
|
103
105
|
});
|
|
104
106
|
},
|
|
105
|
-
|
|
106
|
-
if (!v.results.template?.startsWith("+next")) return;
|
|
107
|
-
if (config.eslint !== void 0)
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
107
|
+
lint: async (v) => {
|
|
108
|
+
if (!v.results.template?.startsWith("+next")) return false;
|
|
109
|
+
if (config.eslint !== void 0) {
|
|
110
|
+
return config.eslint ? "eslint" : false;
|
|
111
|
+
}
|
|
112
|
+
if (config.biome !== void 0) {
|
|
113
|
+
return config.biome ? "biome" : false;
|
|
114
|
+
}
|
|
115
|
+
return select({
|
|
116
|
+
message: "Configure linter?",
|
|
117
|
+
initialValue: false,
|
|
118
|
+
options: [
|
|
119
|
+
{
|
|
120
|
+
value: "eslint",
|
|
121
|
+
label: "ESLint"
|
|
122
|
+
},
|
|
123
|
+
{
|
|
124
|
+
value: "biome",
|
|
125
|
+
label: "Biome"
|
|
126
|
+
},
|
|
127
|
+
{
|
|
128
|
+
value: false,
|
|
129
|
+
label: "Disabled"
|
|
130
|
+
}
|
|
131
|
+
]
|
|
111
132
|
});
|
|
112
133
|
},
|
|
113
134
|
installDeps: () => {
|
|
@@ -158,8 +179,8 @@ async function main(config) {
|
|
|
158
179
|
template: options.template,
|
|
159
180
|
outputDir: dest,
|
|
160
181
|
installDeps: options.installDeps,
|
|
161
|
-
|
|
162
|
-
useSrcDir: options.src
|
|
182
|
+
lint: options.lint,
|
|
183
|
+
useSrcDir: options.src,
|
|
163
184
|
initializeGit: config.git,
|
|
164
185
|
log: (message) => {
|
|
165
186
|
info.message(message);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "create-fumadocs-app",
|
|
3
|
-
"version": "15.7.
|
|
3
|
+
"version": "15.7.11",
|
|
4
4
|
"description": "Create a new documentation site with Fumadocs",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"NextJs",
|
|
@@ -29,10 +29,10 @@
|
|
|
29
29
|
"devDependencies": {
|
|
30
30
|
"@types/cross-spawn": "^6.0.6",
|
|
31
31
|
"@types/node": "24.3.1",
|
|
32
|
-
"tinyglobby": "^0.2.
|
|
32
|
+
"tinyglobby": "^0.2.15",
|
|
33
33
|
"typescript": "^5.9.2",
|
|
34
|
-
"
|
|
35
|
-
"
|
|
34
|
+
"tsconfig": "0.0.0",
|
|
35
|
+
"eslint-config-custom": "0.0.0"
|
|
36
36
|
},
|
|
37
37
|
"engines": {
|
|
38
38
|
"node": ">=18.17.0"
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://biomejs.dev/schemas/2.2.0/schema.json",
|
|
3
|
+
"vcs": {
|
|
4
|
+
"enabled": true,
|
|
5
|
+
"clientKind": "git",
|
|
6
|
+
"useIgnoreFile": true
|
|
7
|
+
},
|
|
8
|
+
"files": {
|
|
9
|
+
"ignoreUnknown": true,
|
|
10
|
+
"includes": ["**", "!node_modules", "!.next", "!dist", "!build", "!.source"]
|
|
11
|
+
},
|
|
12
|
+
"formatter": {
|
|
13
|
+
"enabled": true,
|
|
14
|
+
"indentStyle": "space",
|
|
15
|
+
"indentWidth": 2
|
|
16
|
+
},
|
|
17
|
+
"linter": {
|
|
18
|
+
"enabled": true,
|
|
19
|
+
"rules": {
|
|
20
|
+
"recommended": true
|
|
21
|
+
},
|
|
22
|
+
"domains": {
|
|
23
|
+
"next": "recommended",
|
|
24
|
+
"react": "recommended"
|
|
25
|
+
}
|
|
26
|
+
},
|
|
27
|
+
"assist": {
|
|
28
|
+
"actions": {
|
|
29
|
+
"source": {
|
|
30
|
+
"organizeImports": "on"
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { defineCollection, defineConfig } from '@content-collections/core';
|
|
2
2
|
import {
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
frontmatterSchema,
|
|
4
|
+
metaSchema,
|
|
5
5
|
transformMDX,
|
|
6
6
|
} from '@fumadocs/content-collections/configuration';
|
|
7
7
|
|
|
@@ -9,7 +9,7 @@ const docs = defineCollection({
|
|
|
9
9
|
name: 'docs',
|
|
10
10
|
directory: 'content/docs',
|
|
11
11
|
include: '**/*.mdx',
|
|
12
|
-
schema:
|
|
12
|
+
schema: frontmatterSchema,
|
|
13
13
|
transform: transformMDX,
|
|
14
14
|
});
|
|
15
15
|
|
|
@@ -18,7 +18,7 @@ const metas = defineCollection({
|
|
|
18
18
|
directory: 'content/docs',
|
|
19
19
|
include: '**/meta.json',
|
|
20
20
|
parser: 'json',
|
|
21
|
-
schema:
|
|
21
|
+
schema: metaSchema,
|
|
22
22
|
});
|
|
23
23
|
|
|
24
24
|
export default defineConfig({
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { dirname } from 'path';
|
|
2
|
+
import { fileURLToPath } from 'url';
|
|
3
|
+
import { FlatCompat } from '@eslint/eslintrc';
|
|
4
|
+
|
|
5
|
+
const __filename = fileURLToPath(import.meta.url);
|
|
6
|
+
const __dirname = dirname(__filename);
|
|
7
|
+
|
|
8
|
+
const compat = new FlatCompat({
|
|
9
|
+
baseDirectory: __dirname,
|
|
10
|
+
});
|
|
11
|
+
|
|
12
|
+
const eslintConfig = [
|
|
13
|
+
...compat.extends('next/core-web-vitals', 'next/typescript'),
|
|
14
|
+
{
|
|
15
|
+
ignores: [
|
|
16
|
+
'node_modules/**',
|
|
17
|
+
'.next/**',
|
|
18
|
+
'out/**',
|
|
19
|
+
'build/**',
|
|
20
|
+
'.source/**',
|
|
21
|
+
'next-env.d.ts',
|
|
22
|
+
],
|
|
23
|
+
},
|
|
24
|
+
];
|
|
25
|
+
|
|
26
|
+
export default eslintConfig;
|
|
@@ -5,9 +5,3 @@ import { HomeLayout } from 'fumadocs-ui/layouts/home';
|
|
|
5
5
|
export default function Layout({ children }: { children: ReactNode }) {
|
|
6
6
|
return <HomeLayout {...baseOptions()}>{children}</HomeLayout>;
|
|
7
7
|
}
|
|
8
|
-
|
|
9
|
-
export const getConfig = async () => {
|
|
10
|
-
return {
|
|
11
|
-
render: 'static',
|
|
12
|
-
};
|
|
13
|
-
};
|