TypeScript Awesome Template Literal Types
Curated list of awesome Template Literal Types examples.
🤯 Pure Madness
typescript-types-only-wasm-runtime
typescript-types-only-wasm-runtime repo
📚 Handbook
📰 Articles
- I need to learn about TypeScript Template Literal Types
- TypeScript: Template Literal Types
- Exploring Template Literal Types in TypeScript 4.1
- TypeScript Splits the Atom!
- Mastering TypeScript Template Literal Types
📺 Videos
- It's Clash of Code but with TypeScript only by William Candillon
- It's Brainf**k , but types only by William Candillon
- It's Wordle, but types only by William Candillon
- All 140 TypeScript Challenges - Video Solutions and Explanations by Michigan TypeScript
👀 Examples
- dot notation string type-safe
- document.querySelector
- Router params parsing
- static-path library
- Expression parser
- JSON Parser
- JSON Serializer
- GraphQL Typed AST
- SQL Database
- CSS Parser
- ELIZA Bot
- Typescript Type System Adventure - by Rick Love
- Printf/Log
- Bitwise Arithmetic
- tRPC
- Split
- Privatized
- Join
- Extract all paths from object
- Repeat
- Schummar-translate
- kysely
- chicane
- prefix-properties
- typelevel-parser
- type-trident
- hypescript
- anysort
- wordle
- pretty-cache-header
- nanostores-router
- dot-path-value
- infer-html-events
- hotscript
- brouther
- hkt-toolbelt
- string-ts
- typeskell
- gql.tada
🗂️ Use Cases
dot notation string type-safe
document.querySelector
Router params parsing
static-path library
Expression parser
JSON Parser
JSON Serializer
GraphQL Typed AST
SQL Database
CSS Parser
ELIZA Bot
Typescript Type System Adventure - by Rick Love
Printf/Log
Similar to Idris' type-safe dependently-typed printf, but in TypeScript, working with console.log.
Bitwise Arithmetic
tRPC
TypeScript toolkit for building end-to-end type-safe APIs
The client above is not importing any code from the server, only it's type declarations.
Split
Split a string value with a given sepatator
Privatized
Automaticly privatize methods prefixed by '_'
Join
Type safe ReadonlyArray<string>.join
Extract all paths from object
Repeat
schummar-translate
Extract typed ICU params from translation strings
kysely
A type-safe typescript SQL query builder
chicane
A simple and safe router for React and TypeScript, based on template literal types capabilities.
Prefix Properties
Typelevel Parser
TypeLevel DSL Parser
Type-Trident
A curated list of advanced type level madness
HypeScript
A simplified implementation of TypeScript's type system written in TypeScript's own type system
Anysort
Anysort,Flexible and Full Typed multi-properties sorter for nested objects
Wordle
A pure type only implementation of Wordle game
pretty-cache-header
Cache-control header utility that parses human readable time strings into seconds. Time based values use Template Literal Types to help avoid passing invalid time string formats.
nanostores-router
A tiny URL router for Nano Stores state manager.
dot-path-value
Safely get deep nested properties using dot notation.
infer-html-events
Infer event names out of HTML elements
hotscript
Higher-Order TypeScript: A lodash-like library for types, with support for type-level lambda functions.
https://user-images.githubusercontent.com/2315749/222081717-96217cd2-ac89-4e06-a942-17fbda717cd2.mp4
brouther
The brother router to help in React apps
hkt-toolbelt
✨ Functional and composable type utilities
string-ts
Strongly-typed string functions for all!
typeskell
Experiment to declare typesclasses with programmatic type signatures.
gql.tada
🪄 Magical GraphQL query engine for TypeScript