Skip to content

Commit

Permalink
docs next version base
Browse files Browse the repository at this point in the history
  • Loading branch information
davemooreuws committed Sep 24, 2024
1 parent eccd4d8 commit 9eac4f9
Show file tree
Hide file tree
Showing 88 changed files with 11,346 additions and 0 deletions.
3 changes: 3 additions & 0 deletions v2/.eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"extends": "next/core-web-vitals"
}
35 changes: 35 additions & 0 deletions v2/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
/.pnp
.pnp.js

# testing
/coverage

# next.js
/.next/
/out/

# production
/build

# misc
.DS_Store
*.pem

# debug
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# local env files
.env*.local

# vercel
.vercel

# typescript
*.tsbuildinfo
next-env.d.ts
10 changes: 10 additions & 0 deletions v2/mdx-components.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
import { type MDXComponents } from 'mdx/types'

import * as mdxComponents from '@/components/mdx'

export function useMDXComponents(components: MDXComponents) {
return {
...components,
...mdxComponents,
}
}
26 changes: 26 additions & 0 deletions v2/next.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
import nextMDX from '@next/mdx'

import { recmaPlugins } from './src/mdx/recma.mjs'
import { rehypePlugins } from './src/mdx/rehype.mjs'
import { remarkPlugins } from './src/mdx/remark.mjs'
import withSearch from './src/mdx/search.mjs'

const withMDX = nextMDX({
options: {
remarkPlugins,
rehypePlugins,
recmaPlugins,
},
})

/** @type {import('next').NextConfig} */
const nextConfig = {
pageExtensions: ['js', 'jsx', 'ts', 'tsx', 'mdx'],
experimental: {
outputFileTracingIncludes: {
'/**/*': ['./src/app/**/*.mdx'],
},
},
}

export default withSearch(withMDX(nextConfig))
57 changes: 57 additions & 0 deletions v2/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
{
"name": "nitric-docs-v2",
"version": "0.1.0",
"private": true,
"scripts": {
"dev": "next dev",
"build": "next build",
"start": "next start",
"lint": "next lint"
},
"browserslist": "defaults, not ie <= 11",
"dependencies": {
"@algolia/autocomplete-core": "^1.7.3",
"@headlessui/react": "^2.1.0",
"@headlessui/tailwindcss": "^0.2.0",
"@mdx-js/loader": "^3.0.0",
"@mdx-js/react": "^3.0.0",
"@next/mdx": "^14.0.4",
"@sindresorhus/slugify": "^2.1.1",
"@tailwindcss/typography": "^0.5.10",
"@types/mdx": "^2.0.8",
"@types/node": "^20.10.8",
"@types/react": "^18.2.47",
"@types/react-dom": "^18.2.18",
"@types/react-highlight-words": "^0.16.4",
"acorn": "^8.8.1",
"autoprefixer": "^10.4.7",
"clsx": "^2.1.0",
"fast-glob": "^3.3.0",
"flexsearch": "^0.7.31",
"framer-motion": "^10.18.0",
"mdast-util-to-string": "^4.0.0",
"mdx-annotations": "^0.1.1",
"next": "^14.0.4",
"next-themes": "^0.2.1",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-highlight-words": "^0.20.0",
"remark": "^15.0.1",
"remark-gfm": "^4.0.0",
"remark-mdx": "^3.0.0",
"shiki": "^0.14.7",
"simple-functional-loader": "^1.2.1",
"tailwindcss": "^3.4.1",
"typescript": "^5.3.3",
"unist-util-filter": "^5.0.1",
"unist-util-visit": "^5.0.0",
"zustand": "^4.3.2"
},
"devDependencies": {
"eslint": "^8.56.0",
"eslint-config-next": "^14.0.4",
"prettier": "^3.3.2",
"prettier-plugin-tailwindcss": "^0.6.5",
"sharp": "0.33.1"
}
}
6 changes: 6 additions & 0 deletions v2/postcss.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
module.exports = {
plugins: {
tailwindcss: {},
autoprefixer: {},
},
}
6 changes: 6 additions & 0 deletions v2/prettier.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
/** @type {import('prettier').Options} */
module.exports = {
singleQuote: true,
semi: false,
plugins: ['prettier-plugin-tailwindcss'],
}
Loading

0 comments on commit 9eac4f9

Please sign in to comment.