UNPKG
type-enhancers
Version:
latest (0.8.0)
0.8.0
0.7.5
0.6.5
0.6.4
0.6.1
0.6.0
0.5.2
0.5.1
0.4.1
0.3.0
0.2.0
0.1.0
0.0.9
0.0.8
0.0.7
0.0.6
0.0.5
0.0.4
0.0.3
0.0.2
0.0.1
Enhanced type system
github.com/EzioMercer/type-enhancers
EzioMercer/type-enhancers
type-enhancers
/
utils
/
TrimEnd.d.ts
4 lines
(2 loc)
•
149 B
TypeScript
View Raw
1
2
3
4
import
type
{
WhiteSpace
}
from
'./WhiteSpace'
;
export
type
TrimEnd
<T
extends
string
> = T
extends
`
${infer Rest}
${WhiteSpace}
`
?
TrimEnd
<
Rest
> : T;