Skip to content
Myr

fix(client): set Path as the default of Original (#3058)

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by m-shaka · committed by GitHub · parent 2d3bc55 · Browse files · 2 files+35 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

2 files+35 added−1 removed

  • tests:+34 added−0 removed
  • other:+1 added−1 removed

2 files+35 added−1 removed

modified:src/client/types.test.ts+34 added
modified:src/client/types.ts+1 added-1 removed
144 unmodified lines
145146type PathToChain<147 Path extends string,148 E extends Schema,149 Original extends string = ''149 Original extends string = Path150> = Path extends `/${infer P}`151 ? PathToChain<P, E, Path>152 : Path extends `${infer P}/${infer R}`153 ? { [K in P]: PathToChain<R, E, Original> }
26 unmodified lines