0
Fork 0
mirror of https://github.com/verdaccio/verdaccio.git synced 2024-12-30 22:34:10 -05:00

feat: add typescript project references settings (#1933)

Add two different settings for compile and develop.

https://www.typescriptlang.org/docs/handbook/project-references.html
This commit is contained in:
Juan Picado 2020-09-07 07:07:05 +02:00
parent ddb42431d1
commit aa763baec1
80 changed files with 761 additions and 161 deletions

View file

@ -0,0 +1,37 @@
---
'@verdaccio/api': minor
'@verdaccio/auth': minor
'@verdaccio/cli': minor
'@verdaccio/dev-commons': minor
'@verdaccio/config': minor
'@verdaccio/commons-api': minor
'@verdaccio/file-locking': minor
'@verdaccio/htpasswd': minor
'@verdaccio/local-storage': minor
'@verdaccio/readme': minor
'@verdaccio/streams': minor
'@verdaccio/types': minor
'@verdaccio/hooks': minor
'@verdaccio/loaders': minor
'@verdaccio/logger': minor
'@verdaccio/logger-prettify': minor
'@verdaccio/middleware': minor
'@verdaccio/mock': minor
'@verdaccio/node-api': minor
'@verdaccio/proxy': minor
'@verdaccio/server': minor
'@verdaccio/store': minor
'@verdaccio/dev-types': minor
'@verdaccio/utils': minor
'verdaccio': minor
'@verdaccio/web': minor
'@verdaccio/website': minor
---
feat: add typescript project references settings
Reading https://ebaytech.berlin/optimizing-multi-package-apps-with-typescript-project-references-d5c57a3b4440 I realized I can use project references to solve the issue to pre-compile modules on develop mode.
It allows to navigate (IDE) trough the packages without need compile the packages.
Add two `tsconfig`, one using the previous existing configuration that is able to produce declaration files (`tsconfig.build`) and a new one `tsconfig` which is enables [_projects references_](https://www.typescriptlang.org/docs/handbook/project-references.html).

View file

@ -13,3 +13,4 @@
CHANGELOG.md CHANGELOG.md
CONTRIBUTORS.md CONTRIBUTORS.md
node_modules/ node_modules/
packages/core/local-storage/_storage/**

View file

@ -101,7 +101,8 @@
"verdaccio-memory": "latest" "verdaccio-memory": "latest"
}, },
"scripts": { "scripts": {
"debug": "node debug/bootstrap.js", "start": "node packages/verdaccio/debug/bootstrap.js",
"debug": "node --inspect packages/verdaccio/debug/bootstrap.js",
"dev": "cross-env BABEL_ENV=registry babel-node --extensions \".ts,.tsx\" packages/cli/src", "dev": "cross-env BABEL_ENV=registry babel-node --extensions \".ts,.tsx\" packages/cli/src",
"clean": "pnpm recursive run clean", "clean": "pnpm recursive run clean",
"build": "pnpm recursive run build", "build": "pnpm recursive run build",

View file

@ -16,9 +16,9 @@
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest",
"type-check": "tsc --noEmit", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "cross-env BABEL_ENV=registry babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, },
"license": "MIT", "license": "MIT",

View file

@ -0,0 +1,9 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*", "types/*.d.ts"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,9 +1,47 @@
{ {
"extends": "../../tsconfig", "extends": "../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build" "outDir": "./build"
}, },
"include": ["src/**/*", "types/*.d.ts"], "include": ["src/**/*.ts", "types/*.d.ts"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"],
"references": [
{
"path": "../utils"
},
{
"path": "../config"
},
{
"path": "../commons"
},
{
"path": "../hooks"
},
{
"path": "../store"
},
{
"path": "../types"
},
{
"path": "../middleware"
},
{
"path": "../auth"
},
{
"path": "../server"
},
{
"path": "../loaders"
},
{
"path": "../logger"
},
{
"path": "../core/commons-api"
}
]
} }

View file

@ -16,9 +16,9 @@
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest",
"type-check": "tsc --noEmit", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "cross-env BABEL_ENV=registry babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, },
"license": "MIT", "license": "MIT",

View file

@ -0,0 +1,9 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,9 +1,32 @@
{ {
"extends": "../../tsconfig", "extends": "../../tsconfig.reference",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build" "outDir": "./build"
}, },
"include": ["src/**/*"], "include": ["src/**/*.ts"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"],
"references": [
{
"path": "../utils"
},
{
"path": "../commons"
},
{
"path": "../loaders"
},
{
"path": "../logger"
},
{
"path": "../config"
},
{
"path": "../mock"
},
{
"path": "../core/commons-api"
}
]
} }

View file

@ -21,11 +21,10 @@
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest",
"type-check": "tsc --noEmit", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "cross-env BABEL_ENV=registry babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types", "build": "pnpm run build:js && pnpm run build:types"
"bundle": "cross-env BABEL_ENV=registry webpack --config scripts/bundle.js --profile --json > compilation-stats.json"
}, },
"dependencies": { "dependencies": {
"@verdaccio/config": "workspace:5.0.0-alpha.0", "@verdaccio/config": "workspace:5.0.0-alpha.0",
@ -37,6 +36,5 @@
"kleur": "3.0.3", "kleur": "3.0.3",
"lodash": "^4.17.20", "lodash": "^4.17.20",
"semver": "7.3.2" "semver": "7.3.2"
}, }
"gitHead": "7c246ede52ff717707fcae66dd63fc4abd536982"
} }

View file

@ -0,0 +1,9 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,9 +1,23 @@
{ {
"extends": "../../tsconfig", "extends": "../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build" "outDir": "./build"
}, },
"include": ["src/**/*"], "include": ["src/**/*"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"],
"references": [
{
"path": "../config"
},
{
"path": "../logger"
},
{
"path": "../node-api"
},
{
"path": "../utils"
}
]
} }

View file

@ -1,7 +1,7 @@
{ {
"name": "@verdaccio/dev-commons", "name": "@verdaccio/dev-commons",
"version": "5.0.0-alpha.0", "version": "5.0.0-alpha.0",
"description": "loaders logic", "description": "commons utilities",
"main": "./build/index.js", "main": "./build/index.js",
"types": "build/index.d.ts", "types": "build/index.d.ts",
"author": { "author": {
@ -19,10 +19,9 @@
}, },
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"type-check": "tsc --noEmit", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "cross-env BABEL_ENV=registry babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, }
"gitHead": "7c246ede52ff717707fcae66dd63fc4abd536982"
} }

View file

@ -0,0 +1,9 @@
{
"extends": "../../tsconfig.base",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*.ts"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,9 +1,9 @@
{ {
"extends": "../../tsconfig", "extends": "../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build" "outDir": "./build"
}, },
"include": ["src/**/*"], "include": ["src/**/*.ts"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"]
} }

View file

@ -17,9 +17,9 @@
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest",
"type-check": "tsc --noEmit", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "cross-env BABEL_ENV=registry babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, },
"devDependencies": { "devDependencies": {

View file

@ -0,0 +1,9 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,9 +1,20 @@
{ {
"extends": "../../tsconfig", "extends": "../../tsconfig.reference",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build" "outDir": "./build"
}, },
"include": ["src/**/*"], "include": ["src/**/*.ts"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"],
"references": [
{
"path": "../utils"
},
{
"path": "../commons"
},
{
"path": "../logger"
}
]
} }

View file

@ -36,9 +36,8 @@
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest",
"type-check": "tsc --noEmit", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build:js": "cross-env babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, },
"funding": { "funding": {

View file

@ -0,0 +1,9 @@
{
"extends": "../../../tsconfig.base.json",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,9 +1,11 @@
{ {
"extends": "../../../tsconfig", "extends": "../../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build" "outDir": "./build",
"composite": true,
"declaration": true
}, },
"include": ["src/**/*"], "include": ["src/**/*.ts"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"]
} }

View file

@ -35,8 +35,7 @@
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest",
"type-check": "tsc --noEmit", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true",
"build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, },

View file

@ -0,0 +1,9 @@
{
"extends": "../../../tsconfig.base.json",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,9 +1,9 @@
{ {
"extends": "../../../tsconfig", "extends": "../../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./", "rootDir": "./",
"outDir": "./build" "outDir": "./build"
}, },
"include": ["src/**/*", "types/*.d.ts"], "include": ["src/**/*.ts", "types/*.d.ts"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"]
} }

View file

@ -13,17 +13,20 @@
"homepage": "https://verdaccio.org", "homepage": "https://verdaccio.org",
"repository": { "repository": {
"type": "git", "type": "git",
"url": "https://github.com/verdaccio/monorepo", "url": "https://github.com/verdaccio/verdaccio",
"directory": "plugins/htpasswd" "directory": "packages/core/htpasswd"
}, },
"bugs": { "bugs": {
"url": "https://github.com/verdaccio/monorepo/issues" "url": "https://github.com/verdaccio/verdaccio/issues"
}, },
"main": "./build/index.js", "main": "./build/index.js",
"types": "./build/index.d.ts", "types": "./build/index.d.ts",
"files": [ "files": [
"build" "build"
], ],
"engines": {
"node": ">=10"
},
"dependencies": { "dependencies": {
"@verdaccio/file-locking": "workspace:*", "@verdaccio/file-locking": "workspace:*",
"apache-md5": "1.1.2", "apache-md5": "1.1.2",
@ -38,8 +41,8 @@
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest",
"type-check": "tsc --noEmit", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, },

View file

@ -0,0 +1,9 @@
{
"extends": "../../../tsconfig.base.json",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,9 +1,14 @@
{ {
"extends": "../../../tsconfig", "extends": "../../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build" "outDir": "./build"
}, },
"include": ["src/**/*"], "include": ["src/**/*"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"],
"references": [
{
"path": "../file-locking"
}
]
} }

View file

@ -13,11 +13,11 @@
"homepage": "https://verdaccio.org", "homepage": "https://verdaccio.org",
"repository": { "repository": {
"type": "git", "type": "git",
"url": "https://github.com/verdaccio/monorepo", "url": "https://github.com/verdaccio/verdaccio",
"directory": "plugins/local-storage" "directory": "packages/core/local-storage"
}, },
"bugs": { "bugs": {
"url": "https://github.com/verdaccio/monorepo/issues" "url": "https://github.com/verdaccio/verdaccio/issues"
}, },
"publishConfig": { "publishConfig": {
"access": "public" "access": "public"
@ -28,7 +28,7 @@
"build/" "build/"
], ],
"engines": { "engines": {
"node": ">=8" "node": ">=10"
}, },
"dependencies": { "dependencies": {
"@verdaccio/commons-api": "workspace:*", "@verdaccio/commons-api": "workspace:*",
@ -49,8 +49,8 @@
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest",
"type-check": "tsc --noEmit", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, },

View file

@ -0,0 +1,9 @@
{
"extends": "../../../tsconfig.base.json",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,9 +1,20 @@
{ {
"extends": "../../../tsconfig", "extends": "../../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build" "outDir": "./build"
}, },
"include": ["src/**/*"], "include": ["src/**/*"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"],
"references": [
{
"path": "../streams"
},
{
"path": "../file-locking"
},
{
"path": "../commons-api"
}
]
} }

View file

@ -40,8 +40,7 @@
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest",
"type-check": "tsc --noEmit", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true",
"build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, },

View file

@ -0,0 +1,9 @@
{
"extends": "../../../tsconfig.base.json",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,9 +1,13 @@
{ {
"extends": "../../../tsconfig", "extends": "../../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build" "outDir": "./build",
"preserveSymlinks": true,
"composite": true,
"declaration": true,
"declarationMap": true
}, },
"include": ["src/**/*"], "include": ["src/**/*.ts"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"]
} }

View file

@ -28,8 +28,8 @@
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest",
"type-check": "tsc --noEmit", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, },

View file

@ -0,0 +1,9 @@
{
"extends": "../../../tsconfig.base.json",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,5 +1,5 @@
{ {
"extends": "../../../tsconfig", "extends": "../../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build" "outDir": "./build"

View file

@ -32,9 +32,9 @@
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest",
"type-check": "tsc --noEmit", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "cross-env BABEL_ENV=registry babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, },
"gitHead": "7c246ede52ff717707fcae66dd63fc4abd536982" "gitHead": "7c246ede52ff717707fcae66dd63fc4abd536982"

View file

@ -0,0 +1,9 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,9 +1,29 @@
{ {
"extends": "../../tsconfig", "extends": "../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build" "outDir": "./build"
}, },
"include": ["src/**/*"], "include": ["src/**/*"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"],
"references": [
{
"path": "../config"
},
{
"path": "../auth"
},
{
"path": "../commons"
},
{
"path": "../logger"
},
{
"path": "../utils"
},
{
"path": "../core/commons-api"
}
]
} }

View file

@ -30,9 +30,9 @@
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest",
"type-check": "tsc --noEmit", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "cross-env BABEL_ENV=registry babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, },
"gitHead": "7c246ede52ff717707fcae66dd63fc4abd536982" "gitHead": "7c246ede52ff717707fcae66dd63fc4abd536982"

View file

@ -0,0 +1,9 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,10 +1,29 @@
{ {
"extends": "../../tsconfig", "extends": "../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build", "outDir": "./build"
"allowSyntheticDefaultImports": true
}, },
"include": ["src/**/*"], "include": ["src/**/*.ts"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"],
"references": [
{
"path": "../config"
},
{
"path": "../logger"
},
{
"path": "../mock"
},
{
"path": "../node-api"
},
{
"path": "../core/commons-api"
},
{
"path": "../common"
}
]
} }

View file

@ -17,8 +17,9 @@
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest",
"build:types": "tsc --emitDeclarationOnly --declaration true", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:js": "cross-env BABEL_ENV=registry babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, },
"dependencies": { "dependencies": {

View file

@ -0,0 +1,9 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*.ts"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,10 +1,10 @@
{ {
"extends": "../../tsconfig", "extends": "../../tsconfig.reference",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build", "outDir": "./build"
"allowSyntheticDefaultImports": true
}, },
"include": ["src/**/*"], "include": ["src/**/*.ts"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"],
"references": [{ "path": "../commons" }, { "path": "../core/commons-api" }]
} }

View file

@ -17,8 +17,9 @@
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest --runTestsByPath", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest --runTestsByPath",
"type-check": "tsc --noEmit", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "cross-env BABEL_ENV=registry babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps" "build": "cross-env BABEL_ENV=registry babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps"
}, },
"dependencies": { "dependencies": {

View file

@ -0,0 +1,9 @@
{
"extends": "../../tsconfig.base",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*.ts"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,10 +1,14 @@
{ {
"extends": "../../tsconfig", "extends": "../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build", "outDir": "./build"
"allowSyntheticDefaultImports": true
}, },
"include": ["src/**/*"], "include": ["src/**/*.ts"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"],
"references": [
{
"path": "../logger-prettify"
}
]
} }

View file

@ -16,9 +16,9 @@
"homepage": "https://verdaccio.org", "homepage": "https://verdaccio.org",
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"type-check": "tsc --noEmit", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "cross-env BABEL_ENV=registry babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, },
"dependencies": { "dependencies": {

View file

@ -0,0 +1,9 @@
{
"extends": "../../tsconfig.base",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*.ts"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,9 +1,23 @@
{ {
"extends": "../../tsconfig", "extends": "../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build" "outDir": "./build"
}, },
"include": ["src/**/*", "types/*.d.ts"], "include": ["src/**/*", "types/*.d.ts"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"],
"references": [
{
"path": "../core/commons-api"
},
{
"path": "../commons"
},
{
"path": "../logger"
},
{
"path": "../utils"
}
]
} }

View file

@ -17,9 +17,9 @@
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest",
"type-check": "tsc --noEmit", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "cross-env BABEL_ENV=registry babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, },
"dependencies": { "dependencies": {

View file

@ -0,0 +1,9 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*.ts"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,9 +1,17 @@
{ {
"extends": "../../tsconfig", "extends": "../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build" "outDir": "./build"
}, },
"include": ["src/**/*"], "include": ["src/**/*"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"],
"references": [
{
"path": "../commons"
},
{
"path": "../utils"
}
]
} }

View file

@ -15,9 +15,9 @@
"homepage": "https://verdaccio.org", "homepage": "https://verdaccio.org",
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"type-check": "tsc --noEmit", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "cross-env BABEL_ENV=registry babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types", "build": "pnpm run build:js && pnpm run build:types",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest" "test": "cross-env NODE_ENV=test BABEL_ENV=test jest"
}, },
@ -36,6 +36,5 @@
}, },
"publishConfig": { "publishConfig": {
"access": "public" "access": "public"
}, }
"gitHead": "7c246ede52ff717707fcae66dd63fc4abd536982"
} }

View file

@ -0,0 +1,9 @@
{
"extends": "../../tsconfig.base",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*.ts"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,9 +1,26 @@
{ {
"extends": "../../tsconfig", "extends": "../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build" "outDir": "./build"
}, },
"include": ["src/**/*"], "include": ["src/**/*"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"],
"references": [
{
"path": "../commons"
},
{
"path": "../logger"
},
{
"path": "../server"
},
{
"path": "../mock"
},
{
"path": "../utils"
}
]
} }

View file

@ -17,9 +17,9 @@
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest",
"type-check": "tsc --noEmit", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "cross-env BABEL_ENV=registry babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, },
"dependencies": { "dependencies": {

View file

@ -0,0 +1,9 @@
{
"extends": "../../tsconfig.base",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*.ts"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,9 +1,26 @@
{ {
"extends": "../../tsconfig", "extends": "../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build" "outDir": "./build"
}, },
"include": ["src/**/*"], "include": ["src/**/*", "types/*.d.ts"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"],
"references": [
{
"path": "../core/local-storage"
},
{
"path": "../core/streams"
},
{
"path": "../commons"
},
{
"path": "../logger"
},
{
"path": "../utils"
}
]
} }

View file

@ -1,7 +1,7 @@
{ {
"name": "@verdaccio/server", "name": "@verdaccio/server",
"version": "5.0.0-alpha.0", "version": "5.0.0-alpha.0",
"description": "verdaccio server logic", "description": "server logic",
"main": "./build/index.js", "main": "./build/index.js",
"types": "build/index.d.ts", "types": "build/index.d.ts",
"author": { "author": {
@ -42,10 +42,9 @@
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest",
"type-check": "tsc --noEmit", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "cross-env BABEL_ENV=registry babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, }
"gitHead": "7c246ede52ff717707fcae66dd63fc4abd536982"
} }

View file

@ -0,0 +1,9 @@
{
"extends": "../../tsconfig.base",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*.ts", "types/*.d.ts"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,10 +1,50 @@
{ {
"extends": "../../tsconfig", "extends": "../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build", "outDir": "./build"
"allowSyntheticDefaultImports": true
}, },
"include": ["src/**/*", "types/*.d.ts"], "include": ["src/**/*", "types/*.d.ts"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"],
"references": [
{
"path": "../api"
},
{
"path": "../auth"
},
{
"path": "../config"
},
{
"path": "../commons"
},
{
"path": "../loaders"
},
{
"path": "../logger"
},
{
"path": "../middleware"
},
{
"path": "../store"
},
{
"path": "../utils"
},
{
"path": "../web"
},
{
"path": "../core/commons-api"
},
{
"path": "../proxy"
},
{
"path": "../mock"
}
]
} }

View file

@ -17,9 +17,9 @@
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest",
"type-check": "tsc --noEmit", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "cross-env babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, },
"dependencies": { "dependencies": {
@ -42,6 +42,5 @@
"@verdaccio/dev-types": "workspace:5.0.0-alpha.0", "@verdaccio/dev-types": "workspace:5.0.0-alpha.0",
"@verdaccio/mock": "workspace:5.0.0-alpha.0", "@verdaccio/mock": "workspace:5.0.0-alpha.0",
"@verdaccio/types": "workspace:*" "@verdaccio/types": "workspace:*"
}, }
"gitHead": "7c246ede52ff717707fcae66dd63fc4abd536982"
} }

View file

@ -0,0 +1,9 @@
{
"extends": "../../tsconfig.base",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*.ts"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,9 +1,41 @@
{ {
"extends": "../../tsconfig", "extends": "../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build" "outDir": "./build"
}, },
"include": ["src/**/*"], "include": ["src/**/*"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"],
"references": [
{
"path": "../core/commons-api"
},
{
"path": "../commons"
},
{
"path": "../loaders"
},
{
"path": "../core/local-storage"
},
{
"path": "../logger"
},
{
"path": "../proxy"
},
{
"path": "../core/streams"
},
{
"path": "../utils"
},
{
"path": "../config"
},
{
"path": "../mock"
}
]
} }

View file

@ -32,10 +32,9 @@
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest",
"type-check": "tsc --noEmit", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "cross-env BABEL_ENV=registry babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, }
"gitHead": "7c246ede52ff717707fcae66dd63fc4abd536982"
} }

View file

@ -1,7 +1,7 @@
import _ from 'lodash'; import _ from 'lodash';
import { API_ERROR, ROLES, TIME_EXPIRATION_7D, DEFAULT_MIN_LIMIT_PASSWORD } from '@verdaccio/dev-commons'; import { API_ERROR, ROLES, TIME_EXPIRATION_7D, DEFAULT_MIN_LIMIT_PASSWORD } from '@verdaccio/dev-commons';
import { CookieSessionToken, AuthTokenHeader, BasicPayload } from '@verdaccio/dev-types'; import { CookieSessionToken } from '@verdaccio/dev-types';
import { RemoteUser, AllowAccess, PackageAccess, Callback, Config, Security, APITokenOptions, JWTOptions, IPluginAuth } from '@verdaccio/types'; import { RemoteUser, AllowAccess, PackageAccess, Callback, Config, Security, APITokenOptions, JWTOptions, IPluginAuth } from '@verdaccio/types';
import { VerdaccioError } from '@verdaccio/commons-api'; import { VerdaccioError } from '@verdaccio/commons-api';

View file

@ -0,0 +1,8 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*.ts"]
}

View file

@ -1,10 +1,30 @@
{ {
"extends": "../../tsconfig", "extends": "../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build", "outDir": "./build",
"allowSyntheticDefaultImports": true "preserveSymlinks": true,
"composite": true,
"declaration": true,
"declarationMap": true
}, },
"include": ["src/**/*"], "include": ["src/**/*.ts"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"],
"references": [
{
"path": "../core/commons-api"
},
{
"path": "../core/readme"
},
{
"path": "../commons"
},
{
"path": "../logger"
},
{
"path": "../core/commons-api"
}
]
} }

View file

@ -19,11 +19,10 @@
"clean": "rimraf ./build", "clean": "rimraf ./build",
"lint": "eslint . --ext .js,.ts", "lint": "eslint . --ext .js,.ts",
"test": "cross-env NODE_ENV=test jest --config ./test/jest.config.functional.js --testPathPattern ./test/functional/index* --passWithNoTests", "test": "cross-env NODE_ENV=test jest --config ./test/jest.config.functional.js --testPathPattern ./test/functional/index* --passWithNoTests",
"format": "prettier --single-quote --trailing-comma none --write \"{src,test}/**/*.ts\"", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:types": "tsc --emitDeclarationOnly --declaration true", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "cross-env BABEL_ENV=registry babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types", "build": "pnpm run build:js && pnpm run build:types",
"code:build": "cross-env BABEL_ENV=registry babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps inline",
"code:docker-build": "cross-env BABEL_ENV=registry-docker babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\"", "code:docker-build": "cross-env BABEL_ENV=registry-docker babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\"",
"build:docker": "docker build -t verdaccio/verdaccio:local . --no-cache" "build:docker": "docker build -t verdaccio/verdaccio:local . --no-cache"
}, },

View file

@ -1,3 +1,3 @@
// @verdaccio-cli is only accesible via .bin/ folder // @verdaccio-cli is only accesible via .bin/ folder
export { default } from '@verdaccio/node-api'; export { listenDefaultCallback, startVerdaccio } from '@verdaccio/node-api';

View file

@ -0,0 +1,8 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*.ts"]
}

View file

@ -1,9 +1,32 @@
{ {
"extends": "../../tsconfig", "extends": "../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build" "outDir": "./build"
}, },
"include": ["src/**/*"], "include": ["src/**/*"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"],
"references": [
{
"path": "../hooks"
},
{
"path": "../utils"
},
{
"path": "../mocks"
},
{
"path": "../node-api"
},
{
"path": "../cli"
},
{
"path": "../core/htpasswd"
},
{
"path": "../commons"
}
]
} }

View file

@ -25,10 +25,10 @@
}, },
"scripts": { "scripts": {
"clean": "rimraf ./build", "clean": "rimraf ./build",
"type-check": "tsc --noEmit",
"test": "cross-env NODE_ENV=test BABEL_ENV=test jest", "test": "cross-env NODE_ENV=test BABEL_ENV=test jest",
"build:types": "tsc --emitDeclarationOnly --declaration true", "type-check": "tsc --noEmit -p tsconfig.build.json",
"build:js": "cross-env BABEL_ENV=registry babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps", "build:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
"build:js": "babel src/ --out-dir build/ --copy-files --extensions \".ts,.tsx\" --source-maps",
"build": "pnpm run build:js && pnpm run build:types" "build": "pnpm run build:js && pnpm run build:types"
}, },
"gitHead": "7c246ede52ff717707fcae66dd63fc4abd536982" "gitHead": "7c246ede52ff717707fcae66dd63fc4abd536982"

View file

@ -0,0 +1,9 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build"
},
"include": ["src/**/*.ts", "types/*.d.ts"],
"exclude": ["src/**/*.test.ts"]
}

View file

@ -1,9 +1,32 @@
{ {
"extends": "../../tsconfig", "extends": "../../tsconfig.reference.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "./src", "rootDir": "./src",
"outDir": "./build" "outDir": "./build"
}, },
"include": ["src/**/*", "types/*.d.ts"], "include": ["src/**/*", "types/*.d.ts"],
"exclude": ["src/**/*.test.ts"] "exclude": ["src/**/*.test.ts"],
"references": [
{
"path": "../auth"
},
{
"path": "../commons"
},
{
"path": "../loaders"
},
{
"path": "../logger"
},
{
"path": "../middleware"
},
{
"path": "../store"
},
{
"path": "../utils"
}
]
} }

View file

@ -3,10 +3,9 @@
"compilerOptions": { "compilerOptions": {
"target": "esnext", "target": "esnext",
"module": "commonjs", "module": "commonjs",
"declaration": true,
"noImplicitAny": false, "noImplicitAny": false,
"incremental": false,
"strict": true, "strict": true,
"declaration": true,
"strictNullChecks": true, "strictNullChecks": true,
"resolveJsonModule": true, "resolveJsonModule": true,
"allowSyntheticDefaultImports": true, "allowSyntheticDefaultImports": true,

9
tsconfig.reference.json Normal file
View file

@ -0,0 +1,9 @@
{
"extends": "./tsconfig.base.json",
"compilerOptions": {
"preserveSymlinks": true,
"composite": true,
"incremental": true,
"declarationMap": true
}
}