Comments (2)
I can repro doing these steps
git clone https://github.com/justinwoo/io-ts-bug.git
cd io-ts-bug
npm i io-ts
cd child
npm i ../../io-ts-bug
I end up with this
io-ts-bug
node_modules
fp-ts
io-ts
rxjs
symbol-observable
typescript
child
node_modules
fp-ts
io-ts-bug
node_modules
io-ts // <= note that io-ts end up here
rxjs
symbol-observable
Then I think that in crap.ts
import * as t from 'io-ts'
import { c } from 'io-ts-bug/lib/c'
there are two copies of io-ts
involved.
However if you add the io-ts-bug
dependency to child's package.json
"dependencies": {
"io-ts": "^0.3.0",
"io-ts-bug": "../../io-ts-bug"
}
in a fresh install
git clone https://github.com/justinwoo/io-ts-bug.git
cd io-ts-bug
npm i
cd child
# add "io-ts-bug": "../../io-ts-bug" to package.json before the next command
npm i
I end up with this
io-ts-bug
node_modules
fp-ts
io-ts
rxjs
symbol-observable
typescript
child
node_modules
fp-ts
io-ts // <= note that now io-ts is correctly here
io-ts-bug
rxjs
symbol-observable
and typescript doesn't hang. Could you confirm?
from io-ts.
ah, sorry, forgot to mention that the thing happens with linked packages, but yeah, this works. thanks!
from io-ts.
Related Issues (20)
- Cannot generically create type'd union from string literals for an enum HOT 1
- Incorrect `type` resulting type when contains refinement HOT 3
- Generic Types with constraint HOT 1
- Behavior changes and types are incorrect based on `intersection` array order
- Intersection with record whose keys are a custom type HOT 1
- io-ts recursion use issue HOT 4
- Subpath imports in ESM mode HOT 5
- Clarification question - how to work with the type of codecs themselves? HOT 1
- Surprising acceptance of various inputs HOT 1
- ReadonlyNonEmptyArray can't be used in a mapped type HOT 1
- How to generate documentation for types generated with `t.TypeOf` HOT 1
- Difficulties with generic serialisable type HOT 2
- [Question] Typing a generic mapped union HOT 1
- Inference error for `toString` property in intersection types with TypeScript 4.9.5 HOT 1
- `t.TypeOf<keyof<o>>` should return a string union type, not a numeric union type.
- PSA: TS 5.1 can break using this library HOT 1
- Intersection of Function with Object doesn't validate correctly
- t.Int: use Number.isSafeInteger instead of Number.isInteger
- non-enumerable records with extra keys do not pass `io-ts.record.is`, contrary to TypeScript types HOT 12
- partially enumerable record missing enumerable keys passes `record.is`, contrary to TypeScript types
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from io-ts.