source: node_modules/ts-toolbelt/out/Object/ReadonlyKeys.d.ts@ d24f17c

main
Last change on this file since d24f17c was d24f17c, checked in by Aleksandar Panovski <apano77@…>, 15 months ago

Initial commit

  • Property mode set to 100644
File size: 482 bytes
Line 
1import { Equals } from '../Any/Equals';
2/**
3 * @hidden
4 */
5export declare type _ReadonlyKeys<O extends object> = {
6 [K in keyof O]-?: {
7 1: never;
8 0: K;
9 }[Equals<{
10 -readonly [Q in K]: O[K];
11 }, {
12 [Q in K]: O[K];
13 }>];
14}[keyof O];
15/**
16 * Get the keys of `O` that are readonly
17 * @param O
18 * @returns [[Key]]
19 * @example
20 * ```ts
21 * ```
22 */
23export declare type ReadonlyKeys<O extends object> = O extends unknown ? _ReadonlyKeys<O> : never;
Note: See TracBrowser for help on using the repository browser.