Notes/apps/server/package.json

308 lines
8.6 KiB
JSON
Raw Normal View History

{
"name": "@triliumnext/server",
"version": "0.94.0",
"description": "The server-side component of TriliumNext, which exposes the client via the web, allows for sync and provides a REST API for both internal and external use.",
"private": true,
"dependencies": {
"better-sqlite3": "11.10.0"
},
"devDependencies": {
"@electron/remote": "2.1.2",
"@types/archiver": "6.0.3",
"@types/better-sqlite3": "7.6.13",
"@types/cls-hooked": "4.3.9",
"@types/compression": "1.8.0",
"@types/cookie-parser": "1.4.8",
"@types/debounce": "1.2.4",
"@types/ejs": "3.1.5",
"@types/escape-html": "1.0.4",
"@types/express-http-proxy": "1.6.6",
"@types/express-session": "1.18.1",
"@types/fs-extra": "11.0.4",
"@types/html": "1.0.4",
"@types/ini": "4.1.1",
"@types/js-yaml": "4.0.9",
"@types/jsdom": "21.1.7",
"@types/mime-types": "2.1.4",
"@types/multer": "1.4.12",
"@types/safe-compare": "1.1.2",
"@types/sanitize-html": "2.16.0",
"@types/sax": "1.2.7",
"@types/serve-favicon": "2.5.7",
"@types/serve-static": "1.15.7",
"@types/session-file-store": "1.2.5",
"@types/stream-throttle": "0.1.4",
"@types/supertest": "6.0.3",
"@types/swagger-ui-express": "4.1.8",
"@types/tmp": "0.2.6",
"@types/turndown": "5.0.5",
"@types/ws": "8.18.1",
"@types/xml2js": "0.4.14",
"express-http-proxy": "2.1.1",
"@anthropic-ai/sdk": "0.52.0",
"@braintree/sanitize-url": "7.1.1",
2025-04-23 18:38:47 +03:00
"@triliumnext/commons": "workspace:*",
"@triliumnext/express-partial-content": "workspace:*",
2025-04-23 18:38:47 +03:00
"@triliumnext/turndown-plugin-gfm": "workspace:*",
"archiver": "7.0.1",
"async-mutex": "0.5.0",
"axios": "1.9.0",
"bindings": "1.5.0",
"chardet": "2.1.0",
"cheerio": "1.0.0",
"chokidar": "4.0.3",
"cls-hooked": "4.2.2",
"compression": "1.8.0",
"cookie-parser": "1.4.7",
"csrf-csrf": "3.2.2",
"dayjs": "1.11.13",
"debounce": "2.2.0",
"debug": "4.4.1",
"ejs": "3.1.10",
"electron": "36.3.1",
"electron-debug": "4.1.0",
"electron-window-state": "5.0.3",
"escape-html": "1.0.3",
2025-04-22 17:37:02 +03:00
"express": "4.21.2",
"express-openid-connect": "^2.17.1",
"express-rate-limit": "7.5.0",
"express-session": "1.18.1",
"file-uri-to-path": "2.0.0",
"fs-extra": "11.3.0",
2025-04-22 17:37:02 +03:00
"helmet": "8.1.0",
"html": "1.0.0",
"html2plaintext": "2.1.4",
2025-04-23 18:38:47 +03:00
"http-proxy-agent": "7.0.2",
"https-proxy-agent": "7.0.6",
"i18next": "25.2.0",
2025-04-22 17:37:02 +03:00
"i18next-fs-backend": "2.6.0",
"image-type": "6.0.0",
"ini": "5.0.0",
"is-animated": "2.0.2",
"is-svg": "6.0.0",
"jimp": "1.6.0",
"js-yaml": "4.1.0",
2025-04-22 17:37:02 +03:00
"jsdom": "26.1.0",
"marked": "15.0.12",
"mime-types": "3.0.1",
"multer": "2.0.0",
"normalize-strings": "1.1.1",
"ollama": "0.5.15",
"openai": "4.103.0",
"rand-token": "1.0.1",
2025-04-22 17:37:02 +03:00
"safe-compare": "1.1.4",
"sanitize-filename": "1.6.3",
"sanitize-html": "2.17.0",
2025-04-23 18:38:47 +03:00
"sax": "1.4.1",
"serve-favicon": "2.5.0",
"stream-throttle": "0.1.3",
2025-04-22 17:37:02 +03:00
"strip-bom": "5.0.0",
"striptags": "3.2.0",
"supertest": "7.1.1",
"swagger-jsdoc": "6.2.8",
2025-04-22 17:37:02 +03:00
"swagger-ui-express": "5.0.1",
"time2fa": "^1.3.0",
"tmp": "0.2.3",
"turndown": "7.2.0",
"unescape": "1.0.1",
"ws": "8.18.2",
"xml2js": "0.6.2",
2025-05-21 13:30:46 +03:00
"yauzl": "3.2.0"
2025-04-22 17:37:02 +03:00
},
"nx": {
2025-04-30 22:28:25 +03:00
"name": "server",
"targets": {
"serve": {
"executor": "@nx/js:node",
"dependsOn": [
{
2025-05-27 22:26:52 +03:00
"projects": [
"client"
],
"target": "serve"
},
"build-without-client"
],
"continuous": true,
"options": {
"buildTarget": "server:build-without-client:development",
"runBuildTargetDependencies": false
}
},
"package": {
"dependsOn": [
"build"
],
"command": "bash apps/server/scripts/build-server.sh"
},
2025-04-28 22:58:00 +03:00
"start-prod": {
"dependsOn": [
"build"
],
"command": "node apps/server/dist/main.cjs"
2025-04-28 22:58:00 +03:00
},
2025-04-25 09:54:10 +03:00
"docker-build": {
"dependsOn": [
"build"
],
2025-04-29 21:54:40 +03:00
"options": {
"cwd": "{projectRoot}"
},
"executor": "nx:run-commands",
"defaultConfiguration": "alpine",
"configurations": {
"debian": {
"command": "docker build . -t triliumnext-debian -f Dockerfile"
},
"alpine": {
"command": "docker build . -t triliumnext-alpine -f Dockerfile.alpine"
},
"rootless-debian": {
"command": "docker build . -t triliumnext-rootless-debian -f Dockerfile.rootless"
},
"rootless-alpine": {
"command": "docker build . -t triliumnext-rootless-alpine -f Dockerfile.alpine.rootless"
}
2025-04-29 21:54:40 +03:00
}
},
"docker-start": {
"dependsOn": [
"docker-build"
],
"executor": "nx:run-commands",
"defaultConfiguration": "alpine",
"configurations": {
"debian": {
"command": "docker run -p 8081:8080 triliumnext-debian"
},
"alpine": {
"command": "docker run -p 8081:8080 triliumnext-alpine"
},
"rootless-debian": {
"command": "docker run -p 8081:8080 triliumnext-rootless-debian"
},
"rootless-alpine": {
"command": "docker run -p 8081:8080 triliumnext-rootless-alpine"
}
}
2025-05-21 13:30:46 +03:00
},
"build-without-client": {
2025-05-21 13:30:46 +03:00
"executor": "@nx/esbuild:esbuild",
"outputs": [
"{options.outputPath}"
],
"options": {
"main": "apps/server/src/main.ts",
"outputPath": "apps/server/dist",
"outputFileName": "main.js",
"tsConfig": "apps/server/tsconfig.app.json",
"platform": "node",
"format": [
"cjs"
2025-05-21 13:30:46 +03:00
],
"esbuildOptions": {
"loader": {
".css": "text"
}
},
2025-05-21 13:30:46 +03:00
"declarationRootDir": "apps/server/src"
},
"configurations": {
"development": {
"minify": false,
"assets": [
{
"glob": "**/*",
"input": "apps/server/src/assets",
"output": "assets"
}
]
2025-05-21 13:30:46 +03:00
}
}
},
"build": {
"executor": "@nx/esbuild:esbuild",
"outputs": [
"{options.outputPath}"
],
"dependsOn": [
"^build",
"client:build"
],
"options": {
"main": "apps/server/src/main.ts",
"outputPath": "apps/server/dist",
"tsConfig": "apps/server/tsconfig.app.json",
"platform": "node",
"external": [
"electron",
"@electron/remote",
"better-sqlite3",
"./xhr-sync-worker.js"
],
"format": [
"cjs"
],
"declarationRootDir": "apps/server/src",
"minify": true,
"thirdParty": true,
"declaration": false,
"esbuildOptions": {
2025-05-25 20:06:04 +03:00
"splitting": false,
"loader": {
".css": "text"
}
},
"additionalEntryPoints": [
"apps/server/src/docker_healthcheck.ts"
],
"assets": [
{
"glob": "**/*",
"input": "apps/server/src/assets",
"output": "assets"
},
{
"glob": "**/*",
"input": "apps/client/dist",
"output": "public"
},
{
"glob": "**/*",
"input": "apps/server/node_modules/better-sqlite3",
"output": "node_modules/better-sqlite3"
},
{
"glob": "**/*",
"input": "apps/server/node_modules/bindings",
"output": "node_modules/bindings"
},
{
"glob": "**/*",
"input": "apps/server/node_modules/file-uri-to-path",
"output": "node_modules/file-uri-to-path"
},
{
"glob": "xhr-sync-worker.js",
"input": "apps/server/node_modules/jsdom/lib/jsdom/living/xhr",
"output": ""
}
]
}
}
}
2025-05-21 13:30:46 +03:00
},
"exports": {
"./package.json": "./package.json",
2025-05-22 15:37:34 +03:00
"./src/*": "./src/*",
2025-05-21 13:30:46 +03:00
".": {
"development": "./src/main.ts",
"types": "./dist/main.d.ts",
"import": "./dist/main.js",
"default": "./dist/main.js"
}
},
"types": "./dist/main.d.ts",
"module": "./dist/main.js",
"main": "./dist/main.js"
}