Dani Guardiola

Results 263 comments of Dani Guardiola

Update, I think that's the issue, since removing the function value from the tests makes it pass. Neat.

Last note, here's a neat table I found explaining the differences: https://www.reddit.com/r/typescript/comments/tq3m4f/the_difference_between_object_and_recordstring/

Why the cast? This also works: ```ts type Diff = { [K in Exclude]: K extends keyof O ? O[K] : K extends keyof O1 ? O1[K] : never; };...

Two notes here: - The "capitalize" challenge should go before this one. - The tests are a bit dumb IMO. This is my solution before I realized this fact: ```ts...

Lol, okay, I think I overcomplicated this a lot: ```ts type UppercaseLetters = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"; type StringToCharUnionHelper< S extends string, Acc = never > = S extends `${infer H}${infer T}` ?...

Here's a version of this solution that uses an accumulator to make the conditional type tail-recursive, therefore enabling the ["Tail-Recursion Elimination on Conditional Types"](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-4-5.html#tail-recursion-elimination-on-conditional-types) feature introduced in TypeScript 4.5, which...

Here's my naïve initial attempt (before reading this solution): ```ts type DecrementMap = { 5: 4; 4: 3; 3: 2; 2: 1; 1: 0; }; type Decrement = N extends...

Working on this. For future reference, this seems to be the place where the dark styles are in the original project: https://github.com/lfades/static-tweet/blob/3105e53bce14fa9a8dd004fb9cd66732069c29c9/components/dark-layout/dark.module.css

@transitive-bullshit see https://github.com/transitive-bullshit/react-static-tweets/issues/23#issuecomment-814783953

[I've worked with the typography plugin too.](https://github.com/tailwindlabs/tailwindcss/discussions/3004) The issue is that the plugin doesn't just style direct descendants of `.prose`. For example, every `p`, no matter how nested, gets selected....