mirror of
https://github.com/GitbookIO/gitbook.git
synced 2026-09-16 15:45:13 +00:00
Support Node.js v20 with @gitbook/icons (#2960)
This commit is contained in:
@@ -0,0 +1,5 @@
|
|||||||
|
---
|
||||||
|
'@gitbook/icons': minor
|
||||||
|
---
|
||||||
|
|
||||||
|
Fix the build to support Node.js v20
|
||||||
@@ -198,7 +198,6 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@gitbook/api": "0.96.1",
|
"@gitbook/api": "0.96.1",
|
||||||
"@gitbook/icons": "workspace:*",
|
"@gitbook/icons": "workspace:*",
|
||||||
"assert-never": "^1.2.1",
|
|
||||||
"classnames": "^2.5.1",
|
"classnames": "^2.5.1",
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
|||||||
@@ -41,5 +41,8 @@
|
|||||||
"bin": {
|
"bin": {
|
||||||
"gitbook-icons": "./bin/gitbook-icons.js"
|
"gitbook-icons": "./bin/gitbook-icons.js"
|
||||||
},
|
},
|
||||||
"files": ["dist", "src", "bin", "data", "README.md", "CHANGELOG.md"]
|
"files": ["dist", "src", "bin", "data", "README.md", "CHANGELOG.md"],
|
||||||
|
"engines": {
|
||||||
|
"node": ">=20.0.0"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import stylesMap from './data/styles-map.json';
|
import stylesMap from './data/styles-map.json' with { type: 'json' };
|
||||||
import type { IconName, IconStyle } from './types';
|
import type { IconName, IconStyle } from './types';
|
||||||
|
|
||||||
const cache = new Map<IconName, Map<IconStyle, [string, IconName]>>();
|
const cache = new Map<IconName, Map<IconStyle, [string, IconName]>>();
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import rawIcons from './data/icons.json';
|
import rawIcons from './data/icons.json' with { type: 'json' };
|
||||||
import type { IconName, IconStyle } from './types';
|
import type { IconName, IconStyle } from './types';
|
||||||
|
|
||||||
export interface IconStyleDefinition {
|
export interface IconStyleDefinition {
|
||||||
|
|||||||
@@ -1,16 +1,16 @@
|
|||||||
{
|
{
|
||||||
"compilerOptions": {
|
"compilerOptions": {
|
||||||
"target": "esnext",
|
"lib": ["es2023"],
|
||||||
"lib": ["dom", "dom.iterable", "esnext"],
|
"module": "ESNext",
|
||||||
"allowJs": true,
|
"target": "es2022",
|
||||||
"skipLibCheck": true,
|
|
||||||
"strict": true,
|
"strict": true,
|
||||||
|
"esModuleInterop": true,
|
||||||
|
"skipLibCheck": true,
|
||||||
|
"moduleResolution": "bundler",
|
||||||
|
"allowJs": true,
|
||||||
"noEmit": false,
|
"noEmit": false,
|
||||||
"declaration": true,
|
"declaration": true,
|
||||||
"outDir": "dist",
|
"outDir": "dist",
|
||||||
"esModuleInterop": true,
|
|
||||||
"module": "esnext",
|
|
||||||
"moduleResolution": "bundler",
|
|
||||||
"resolveJsonModule": true,
|
"resolveJsonModule": true,
|
||||||
"isolatedModules": true,
|
"isolatedModules": true,
|
||||||
"jsx": "react-jsx",
|
"jsx": "react-jsx",
|
||||||
|
|||||||
@@ -11,7 +11,6 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"classnames": "^2.5.1",
|
"classnames": "^2.5.1",
|
||||||
"@gitbook/api": "0.96.1",
|
"@gitbook/api": "0.96.1",
|
||||||
"assert-never": "^1.2.1",
|
|
||||||
"@gitbook/icons": "workspace:*"
|
"@gitbook/icons": "workspace:*"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
|
|||||||
Reference in New Issue
Block a user