Dmitry Ignatov

Results 21 comments of Dmitry Ignatov

So, now you can use this approach: ```js Array & { 0: string, 1: number, length: 2 } ``` for describing a tuple like [string, number]

@brettz9 > Is `&` supported as an operator in jsdoc? I use jsdoc type checking powered by [TypeScript](https://www.typescriptlang.org/docs/handbook/type-checking-javascript-files.html) and intersection works as expected there. Don't know about native jsdoc support.

@HoldYourWaffle @gcanti @josejulio @andykais @vegansk @giogonzo @Lonli-Lokli @steida You're welcome to use my package https://github.com/awerlogus/io-ts-transformer

@andykais @gcanti I just released a new version of my package. Now it can transform recursive types. You already can try it on yourself. https://github.com/awerlogus/io-ts-transformer

@jgbpercy > It looks like you want `as const`: Yes, `as const` works, but I'm asking for type checker mode where all types will be inferred as const by default....

@RyanCavanaugh no, #32758 is not my proposal. They want, for example, use `ReadonlyArray` instead of `Array` for this case ```ts const a = [1, 2, 3] ``` or use readonly...

@RyanCavanaugh please reopen this issue. It is not duplicate.

@RyanCavanaugh as I said 2 times before, I don't ask you to add a compiler mode, where all types will be readonly. My proposal is a mode to make type...

@jgbpercy the expression `as const` is being used to solve two different problems in the same time: the first is inferring types as literal as possible (that thing which I'm...