Merge pull request #881 from timlrx/upgrade/unifiedjs-contentlayer

change to contentlayer2 and update dependencies
This commit is contained in:
Timothy 2024-03-31 21:51:11 +08:00 committed by GitHub
commit 94ac882c83
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 3394 additions and 3636 deletions

View File

@ -1 +1 @@
{"next-js":6,"tailwind":3,"guide":5,"feature":2,"multi-author":1,"hello":1,"math":1,"ols":1,"github":1,"writings":1,"book":1,"reflection":1,"holiday":1,"canada":1,"images":1,"markdown":1,"code":1,"features":1}
{"markdown":1,"code":1,"features":1,"next-js":6,"math":1,"ols":1,"github":1,"guide":5,"tailwind":3,"hello":1,"holiday":1,"canada":1,"images":1,"feature":2,"writings":1,"book":1,"reflection":1,"multi-author":1}

View File

@ -1,4 +1,4 @@
import { defineDocumentType, ComputedFields, makeSource } from 'contentlayer/source-files'
import { defineDocumentType, ComputedFields, makeSource } from 'contentlayer2/source-files'
import { writeFileSync } from 'fs'
import readingTime from 'reading-time'
import { slug } from 'github-slugger'
@ -134,6 +134,7 @@ export default makeSource({
mdx: {
cwd: process.cwd(),
remarkPlugins: [
// @ts-ignore
remarkExtractFrontmatter,
remarkGfm,
remarkCodeTitles,

View File

@ -1,4 +1,4 @@
const { withContentlayer } = require('next-contentlayer')
const { withContentlayer } = require('next-contentlayer2')
const withBundleAnalyzer = require('@next/bundle-analyzer')({
enabled: process.env.ANALYZE === 'true',

View File

@ -11,39 +11,39 @@
"lint": "next lint --fix --dir pages --dir app --dir components --dir lib --dir layouts --dir scripts"
},
"dependencies": {
"@next/bundle-analyzer": "14.1.0",
"@tailwindcss/forms": "^0.5.4",
"@tailwindcss/typography": "^0.5.9",
"@next/bundle-analyzer": "14.1.4",
"@tailwindcss/forms": "^0.5.7",
"@tailwindcss/typography": "^0.5.12",
"autoprefixer": "^10.4.13",
"contentlayer": "0.3.4",
"esbuild": "0.18.11",
"contentlayer2": "0.4.4",
"esbuild": "0.20.2",
"github-slugger": "^2.0.0",
"gray-matter": "^4.0.2",
"image-size": "1.0.0",
"next": "14.1.0",
"next-contentlayer": "0.3.4",
"next-themes": "^0.2.1",
"pliny": "0.1.7",
"next": "14.1.4",
"next-contentlayer2": "0.4.4",
"next-themes": "^0.3.0",
"pliny": "0.2.0",
"postcss": "^8.4.24",
"react": "18.2.0",
"react-dom": "18.2.0",
"reading-time": "1.5.0",
"rehype-autolink-headings": "^6.1.0",
"rehype-citation": "^1.0.2",
"rehype-katex": "^6.0.3",
"rehype-preset-minify": "6.0.0",
"rehype-prism-plus": "^1.6.0",
"rehype-slug": "^5.1.0",
"remark": "^14.0.2",
"remark-gfm": "^3.0.1",
"remark-math": "^5.1.1",
"tailwindcss": "^3.4.1",
"unist-util-visit": "^4.1.0"
"rehype-autolink-headings": "^7.1.0",
"rehype-citation": "^2.0.0",
"rehype-katex": "^7.0.0",
"rehype-preset-minify": "7.0.0",
"rehype-prism-plus": "^2.0.0",
"rehype-slug": "^6.0.0",
"remark": "^15.0.0",
"remark-gfm": "^4.0.0",
"remark-math": "^6.0.0",
"tailwindcss": "^3.4.3",
"unist-util-visit": "^5.0.0"
},
"devDependencies": {
"@svgr/webpack": "^8.0.1",
"@types/mdx": "^2.0.5",
"@types/react": "^18.2.14",
"@types/mdx": "^2.0.12",
"@types/react": "^18.2.73",
"@typescript-eslint/eslint-plugin": "^6.1.0",
"@typescript-eslint/parser": "^6.1.0",
"cross-env": "^7.0.3",
@ -57,15 +57,6 @@
"prettier-plugin-tailwindcss": "^0.5.11",
"typescript": "^5.1.3"
},
"resolutions": {
"@opentelemetry/api": "1.4.1",
"@opentelemetry/core": "1.13.0",
"@opentelemetry/exporter-trace-otlp-grpc": "0.39.1",
"@opentelemetry/resources": "1.13.0",
"@opentelemetry/sdk-trace-base": "1.13.0",
"@opentelemetry/sdk-trace-node": "1.13.0",
"@opentelemetry/semantic-conventions": "1.13.0"
},
"lint-staged": {
"*.+(js|jsx|ts|tsx)": [
"eslint --fix"

6970
yarn.lock

File diff suppressed because it is too large Load Diff