gitr.ee

Code Feed

SA
Sarah Chen@sarahchen5/1/2023
vercel/next-patterns
Pattern
New

React Server Components: Data Fetching Pattern

A clean pattern for fetching data in React Server Components without prop drilling or client-side fetching.

#react
#server-components
#data-fetching
#next.js
28
AL
Alex Johnson@alexjohnson4/28/2023
facebook/react-patterns
Technique

Optimistic UI Updates with React

Implement optimistic UI updates to make your React apps feel faster and more responsive to user actions.

#react
#optimistic-updates
#ui
#performance
42
TA
Taylor Wong@tailwindtaylor4/30/2023
tailwindlabs/tailwindcss
Technique
New

Tailwind CSS Container Queries

Use Tailwind's new container query variants to create components that adapt to their parent container's size.

#tailwindcss
#css
#container-queries
#responsive
15
MA
Maria Rodriguez@mariaai5/2/2023
langchain-ai/langchain-ts
Pattern
New

LangChain Structured Output with Zod

Use Zod with LangChain to validate and type the output from large language models in TypeScript.

#ai
#langchain
#typescript
#zod
#llm
37
JA
Jamie Smith@jamiesmith4/29/2023
shadcn/ui-components
Code Snippet

shadcn/ui Animated Accordion

Create a smooth animated accordion component with shadcn/ui and Framer Motion.

#react
#framer-motion
#animation
#ui
#shadcn
19
LE
Lee Robinson@leeerob5/3/2023
vercel/next.js
Technique
New

Next.js App Router: Parallel Routes

Use Next.js 13's parallel routes feature to render multiple pages in the same layout simultaneously.

#next.js
#app-router
#parallel-routes
#react
42
TO
Tomas Eriksson@typescript_tom5/4/2023
microsoft/typescript-patterns
Pattern
New

TypeScript Discriminated Unions

Use TypeScript's discriminated unions pattern for type-safe handling of different states in your application.

#typescript
#patterns
#discriminated-unions
#type-safety
31
EL
Eliza Weisman@elizarust5/5/2023
vultix/ts-results
Pattern
New

Rust-inspired Result Type in TypeScript

Implement a Rust-like Result type in TypeScript for better error handling without exceptions.

#typescript
#rust
#error-handling
#functional-programming
23