Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/anuraghazra/type-trident

A curated list of advanced type level madness
https://github.com/anuraghazra/type-trident

Last synced: 19 days ago
JSON representation

A curated list of advanced type level madness

Awesome Lists containing this project

README

        


Type Trident Logo

type-trident


A curated list of advanced type level madness

## :magic_wand: List

- [bubble-sort](./src/bubble-sort) | [playground](https://tsplay.dev/Ndo5vw) | [tweet](https://twitter.com/anuraghazru/status/1511776290487279616)
Type level bubble sort algorithm

- [insertion-sort](./src/insertion-sort) | [playground](https://tsplay.dev/w17dOm) | [tweet](https://twitter.com/anuraghazru/status/1591448028640317440)
Type level insertion sort algorithm

- [tic-tac-toe](./src/tic-tac-toe/index.ts) | [playground](https://codesandbox.io/s/type-level-tic-tac-toe-yqbmk9?file=/src/index.ts:2465-2492) | [tweet](https://twitter.com/anuraghazru/status/1530866079999791105)
Type level tic-tac-toe game

- [classnames](./src/classnames/) | [playground](https://tsplay.dev/N7OnqN) | [tweet](https://twitter.com/anuraghazru/status/1401593199148244993)
Type safe version of [classnames package](https://www.npmjs.com/package/classnames)

- [hex-to-rgb](./src/hex-to-rgb/) | [playground](https://tsplay.dev/WPpLEW) | [tweet](https://twitter.com/anuraghazru/status/1464564132045152260)
Type level hex to rgb color conversion

- [url-parser](./src/url-parser/) | [playground](https://tsplay.dev/mMMAlm) | [tweet](https://twitter.com/anuraghazru/status/1467129993402609669)
Type level URL parser

- [math](./src/math/) | [playground](https://tsplay.dev/w65YeW) | [tweet](https://twitter.com/anuraghazru/status/1403756647240003588)
Type level math operations

- [mustache-interpolation](./src/mustache-interpolation/) | [playground](https://tsplay.dev/WPZXJN) | [tweet](https://twitter.com/anuraghazru/status/1311002040672219136)
Type level {{mustache}} string interpolator

- [ds-tokenizer](./src/ds-tokenizer/) | [playground](https://tsplay.dev/w8okdW) | [tweet](https://twitter.com/anuraghazru/status/1501969255696244736)
A theme tokenizer for design systems

- [typed-reactintl](./src/typed-reactintl/) | [playground](https://tsplay.dev/Nlv9GW) | [tweet](https://twitter.com/anuraghazru/status/1459207971838181377)
A type safe version of [ReactIntl](https://www.npmjs.com/package/react-intl) package

- [css-parser](./src/css-parser/) | [playground](https://tsplay.dev/wRRLQw) | [tweet](https://twitter.com/anuraghazru/status/1310634306092462080)
Very buggy type level CSS parser

- [count-generic-args](./src/count-generic-args/) | [playground](https://tsplay.dev/NVZjBN) | [tweet](https://twitter.com/anuraghazru/status/1405925522102657029)
An interesting way of knowing if a generic argument is passed by the user or is set with default value (more info in tweet)

- [tree-api](./src/tree-api/) | [playground](https://tsplay.dev/WoGBgW) | [tweet](https://twitter.com/anuraghazru/status/1383476150362542085)
Type safe tree api

- [typed-regex-named-groups](./src/typed-regex-named-groups) | [playground](https://tsplay.dev/N5LV2w) | [tweet](https://twitter.com/anuraghazru/status/1564980027115986945)
Typesafe RegExp named groups

- [string-to-number](./src/string-to-number) | [playground](https://tsplay.dev/Nr9Law) | [tweet](https://twitter.com/anuraghazru/status/1573328090884980739)
String to number conversion (with floating number supports)

- [Number Range type](./src/range-type) | [playground](https://tsplay.dev/N95d8N) | [tweet](https://twitter.com/anuraghazru/status/1573328100246822917)
Range type which generates union of number between two numbers (with floating number supports)

**Leetcode challenges**

- [Leetcode 1209](./src/leetcode/remove-all-adjacent-duplicates-in-string-2.ts) | [playground](https://tsplay.dev/NDgkxw) | [tweet](https://twitter.com/anuraghazru/status/1673736137373020161)
Remove All Adjacent Duplicates in String II
- [Leetcode 12](./src/leetcode/roman-to-int.ts) | [playground](https://tsplay.dev/Ndarvm) | [tweet](https://twitter.com/anuraghazru/status/1674816392225488896)
Roman to Integer

**And the most crazy one**:

- [Type level parser](https://github.com/anuraghazra/typelevel-parser) - [Tweet](https://twitter.com/anuraghazru/status/1512092136841543682)
An experimental tokenizer/parser/interpreter written entirely on type-level to push the limits of TypeScript's type system.

---

This repository is inspired by [Type Gymnastic](https://github.com/g-plane/type-gymnastics) by g-plane.