Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement live types #3656

Merged
merged 5 commits into from
Jul 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .configs/tsconfig.base.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
"downlevelIteration": true,
"isolatedModules": true,

"pretty": true
"pretty": true,
"customConditions": ["@zod/source"]
}
}
2 changes: 1 addition & 1 deletion biome.jsonc
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,6 @@
}
},
"files": {
"ignore": ["lib", "coverage", "dist"]
"ignore": ["lib", "coverage", "dist", ".tshy", ".tshy-build"]
}
}
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
},
"lint-staged": {
"src/*.ts": ["biome format --write", "biome lint --write"],
"*.json": ["biome format --write", "biome lint --write"],
"*.md": ["prettier --ignore-unknown --write"]
},
"scripts": {
Expand Down
17 changes: 5 additions & 12 deletions packages/effect-plugin/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,10 @@
"type": "module",
"version": "0.1.0",
"author": "Colin McDonnell <zod@colinhacks.com>",
"files": [
"src",
"dist"
],
"files": ["src", "dist"],
"funding": "https://github.com/sponsors/colinhacks",
"homepage": "https://zod.dev",
"keywords": [
"typescript",
"schema",
"validation",
"type",
"inference"
],
"keywords": ["typescript", "schema", "validation", "type", "inference"],
"license": "MIT",
"sideEffects": false,
"main": "./dist/commonjs/index.js",
Expand All @@ -25,6 +16,7 @@
"./package.json": "./package.json",
".": {
"import": {
"@zod/source": "./src/index.ts",
"types": "./dist/esm/index.d.ts",
"default": "./dist/esm/index.js"
},
Expand All @@ -38,7 +30,8 @@
"exports": {
"./package.json": "./package.json",
".": "./src/index.ts"
}
},
"sourceDialects": ["@zod/source"]
},
"repository": {
"type": "git",
Expand Down
21 changes: 9 additions & 12 deletions packages/zod/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,10 @@
"version": "3.23.8",
"author": "Colin McDonnell <zod@colinhacks.com>",
"description": "TypeScript-first schema declaration and validation library with static type inference",
"files": [
"src",
"dist"
],
"files": ["src", "dist"],
"funding": "https://github.com/sponsors/colinhacks",
"homepage": "https://zod.dev",
"keywords": [
"typescript",
"schema",
"validation",
"type",
"inference"
],
"keywords": ["typescript", "schema", "validation", "type", "inference"],
"license": "MIT",
"sideEffects": false,
"main": "./dist/commonjs/index.js",
Expand All @@ -26,6 +17,7 @@
"./package.json": "./package.json",
".": {
"import": {
"@zod/source": "./src/index.ts",
"types": "./dist/esm/index.d.ts",
"default": "./dist/esm/index.js"
},
Expand All @@ -36,6 +28,7 @@
},
"./locales/*": {
"import": {
"@zod/source": "./src/locales/*",
"types": "./dist/esm/locales/*",
"default": "./dist/esm/locales/*"
},
Expand All @@ -50,7 +43,8 @@
"./package.json": "./package.json",
".": "./src/index.ts",
"./locales/*": "./src/locales/*"
}
},
"sourceDialects": ["@zod/source"]
},
"repository": {
"type": "git",
Expand All @@ -70,5 +64,8 @@
"test:watch": "pnpm vitest",
"test": "pnpm vitest run",
"prepublishOnly": "pnpm test && pnpm run build"
},
"dependencies": {
"effect": "^3.5.6"
}
}
6 changes: 5 additions & 1 deletion pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions vitest.root.mts
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
import { type UserConfig, defineConfig } from "vitest/config";

export default defineConfig({
resolve: {
conditions: ["@zod/source"],
},
test: {
watch: false,
isolate: false,
Expand Down