Skip to content

Commit

Permalink
feat(theme): allow recursive partial themes
Browse files Browse the repository at this point in the history
Allow recursive partial themes to be passed to the Setting component. Added RecursivePartial global
type.

Issue #201
  • Loading branch information
nickofthyme committed Jun 14, 2019
1 parent 7261a46 commit 257f649
Show file tree
Hide file tree
Showing 7 changed files with 532 additions and 426 deletions.
7 changes: 7 additions & 0 deletions src/@types/global.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
declare type RecursivePartial<T> = {
[P in keyof T]?: T[P] extends (infer U)[]
? RecursivePartial<U>[]
: T[P] extends readonly (infer U)[] // eslint-disable-line prettier/prettier
? readonly RecursivePartial<U>[]
: RecursivePartial<T[P]>
};
Loading

0 comments on commit 257f649

Please sign in to comment.