Skip to content
This repository was archived by the owner on May 20, 2025. It is now read-only.

Commit d30160d

Browse files
committed
docs next version base
1 parent 173a241 commit d30160d

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

88 files changed

+11346
-0
lines changed

v2/.eslintrc.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"extends": "next/core-web-vitals"
3+
}

v2/.gitignore

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
2+
3+
# dependencies
4+
/node_modules
5+
/.pnp
6+
.pnp.js
7+
8+
# testing
9+
/coverage
10+
11+
# next.js
12+
/.next/
13+
/out/
14+
15+
# production
16+
/build
17+
18+
# misc
19+
.DS_Store
20+
*.pem
21+
22+
# debug
23+
npm-debug.log*
24+
yarn-debug.log*
25+
yarn-error.log*
26+
27+
# local env files
28+
.env*.local
29+
30+
# vercel
31+
.vercel
32+
33+
# typescript
34+
*.tsbuildinfo
35+
next-env.d.ts

v2/mdx-components.tsx

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
import { type MDXComponents } from 'mdx/types'
2+
3+
import * as mdxComponents from '@/components/mdx'
4+
5+
export function useMDXComponents(components: MDXComponents) {
6+
return {
7+
...components,
8+
...mdxComponents,
9+
}
10+
}

v2/next.config.mjs

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
import nextMDX from '@next/mdx'
2+
3+
import { recmaPlugins } from './src/mdx/recma.mjs'
4+
import { rehypePlugins } from './src/mdx/rehype.mjs'
5+
import { remarkPlugins } from './src/mdx/remark.mjs'
6+
import withSearch from './src/mdx/search.mjs'
7+
8+
const withMDX = nextMDX({
9+
options: {
10+
remarkPlugins,
11+
rehypePlugins,
12+
recmaPlugins,
13+
},
14+
})
15+
16+
/** @type {import('next').NextConfig} */
17+
const nextConfig = {
18+
pageExtensions: ['js', 'jsx', 'ts', 'tsx', 'mdx'],
19+
experimental: {
20+
outputFileTracingIncludes: {
21+
'/**/*': ['./src/app/**/*.mdx'],
22+
},
23+
},
24+
}
25+
26+
export default withSearch(withMDX(nextConfig))

v2/package.json

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
{
2+
"name": "nitric-docs-v2",
3+
"version": "0.1.0",
4+
"private": true,
5+
"scripts": {
6+
"dev": "next dev",
7+
"build": "next build",
8+
"start": "next start",
9+
"lint": "next lint"
10+
},
11+
"browserslist": "defaults, not ie <= 11",
12+
"dependencies": {
13+
"@algolia/autocomplete-core": "^1.7.3",
14+
"@headlessui/react": "^2.1.0",
15+
"@headlessui/tailwindcss": "^0.2.0",
16+
"@mdx-js/loader": "^3.0.0",
17+
"@mdx-js/react": "^3.0.0",
18+
"@next/mdx": "^14.0.4",
19+
"@sindresorhus/slugify": "^2.1.1",
20+
"@tailwindcss/typography": "^0.5.10",
21+
"@types/mdx": "^2.0.8",
22+
"@types/node": "^20.10.8",
23+
"@types/react": "^18.2.47",
24+
"@types/react-dom": "^18.2.18",
25+
"@types/react-highlight-words": "^0.16.4",
26+
"acorn": "^8.8.1",
27+
"autoprefixer": "^10.4.7",
28+
"clsx": "^2.1.0",
29+
"fast-glob": "^3.3.0",
30+
"flexsearch": "^0.7.31",
31+
"framer-motion": "^10.18.0",
32+
"mdast-util-to-string": "^4.0.0",
33+
"mdx-annotations": "^0.1.1",
34+
"next": "^14.0.4",
35+
"next-themes": "^0.2.1",
36+
"react": "^18.2.0",
37+
"react-dom": "^18.2.0",
38+
"react-highlight-words": "^0.20.0",
39+
"remark": "^15.0.1",
40+
"remark-gfm": "^4.0.0",
41+
"remark-mdx": "^3.0.0",
42+
"shiki": "^0.14.7",
43+
"simple-functional-loader": "^1.2.1",
44+
"tailwindcss": "^3.4.1",
45+
"typescript": "^5.3.3",
46+
"unist-util-filter": "^5.0.1",
47+
"unist-util-visit": "^5.0.0",
48+
"zustand": "^4.3.2"
49+
},
50+
"devDependencies": {
51+
"eslint": "^8.56.0",
52+
"eslint-config-next": "^14.0.4",
53+
"prettier": "^3.3.2",
54+
"prettier-plugin-tailwindcss": "^0.6.5",
55+
"sharp": "0.33.1"
56+
}
57+
}

v2/postcss.config.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
module.exports = {
2+
plugins: {
3+
tailwindcss: {},
4+
autoprefixer: {},
5+
},
6+
}

v2/prettier.config.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
/** @type {import('prettier').Options} */
2+
module.exports = {
3+
singleQuote: true,
4+
semi: false,
5+
plugins: ['prettier-plugin-tailwindcss'],
6+
}

0 commit comments

Comments
 (0)