Skip to content

Commit

Permalink
Update README and bump version
Browse files Browse the repository at this point in the history
  • Loading branch information
p10ns11y committed Nov 6, 2024
1 parent c36671d commit 25c7d1a
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 8 deletions.
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ Dynamic and Adaptable Model Validator Using Zod, Interoperable with OpenAPI
To install the library, use npm or yarn:

```sh
npm install adaptate
npm install @adaptate/core
# or
yarn add adaptate
yarn add @adaptate/core
```

## Usage
Expand Down Expand Up @@ -89,7 +89,7 @@ You can make a Zod schema required based on a configuration (components need) us

```ts
import { z } from 'zod';
import { makeSchemaRequired } from 'adaptate';
import { makeSchemaRequired } from '@adaptate/core';

const schema = z.object({
name: z.string().optional(),
Expand Down Expand Up @@ -138,7 +138,7 @@ You can apply conditional requirements to a Zod schema using the applyConditiona

```ts
import { z } from 'zod';
import { applyConditionalRequirements } from 'adaptate';
import { applyConditionalRequirements } from '@adaptate/core';

const schema = z.object({
firstName: z.string().optional(),
Expand Down Expand Up @@ -176,7 +176,7 @@ const updatedSchema = applyConditionalRequirements(schema, config, data);
The utility is in the early stage and not one to one. For complete and advanced use cases check [json-schema-to-zod](https://snyk.io/advisor/npm-package/json-schema-to-zod)

```ts
import { openAPISchemaToZod } from 'adaptate';
import { openAPISchemaToZod } from '@adaptate/core';

const openAPISchema = {
type: 'object',
Expand All @@ -199,7 +199,7 @@ The utility is in the early stage and not one to one. For complete and advanced

```ts
import { z } from 'zod';
import { zodToOpenAPISchema } from 'adaptate';
import { zodToOpenAPISchema } from '@adaptate/core';

const zodSchema = z.object({
name: z.string(),
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"workspaces": [
"packages/*"
],
"version": "0.0.7",
"version": "0.0.8",
"author": {
"name": "Peramanathan Sathyamoorthy",
"url": "https://github.com/p10ns11y/adaptate.git"
Expand Down
9 changes: 9 additions & 0 deletions packages/core/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
## Installation

To install the library, use npm or yarn:

```sh
npm install @adaptate/core
# or
yarn add @adaptate/core
```
2 changes: 1 addition & 1 deletion packages/core/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@adaptate/core",
"version": "0.0.7",
"version": "0.0.8",
"author": {
"name": "Peramanathan Sathyamoorthy",
"url": "https://github.com/p10ns11y/adaptate.git"
Expand Down

0 comments on commit 25c7d1a

Please sign in to comment.