Effect-TS / schema

Modeling the schema of data structures as first-class values

Home Page:https://effect.website

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Install instructions incomplete

florianbepunkt opened this issue · comments

What is the type of issue?

Documentation is incorrect, Documentation is confusing, Example code is not working

What is the issue?

const Person = S.struct({
  name: S.string,
  age: S.number,
});

type Person = S.Schema.To<typeof Person>;

Intellisense infers type Person as type Person = Simplify<S.ToStruct<Fields>>

See a very basic repro here:
https://codesandbox.io/s/sweet-mccarthy-t58353?file=/src/index.ts

I believe the installation instructions are incomplete or outdated.

My issue #474 seems to be related.

Where did you find it?

https://github.com/Effect-TS/schema

This is a peer dependency problem. Unfortunately, package managers handle the installation of these very differently. We have some monorepos with npm's legacy peer dependency behavior enabled, so we ended up with effect not being installed.

Probably it makes sense to add a hint to the installation instructions/requirements that effect is a peer dependency.

Probably it makes sense to add a hint to the installation instructions/requirements that effect is a peer dependency.

👍