Animation
- Motion One
From creator of Popmotion, Pose and Framer Motion. For React, use Framer Motion.
- Framer Motion
- AutoAnimate
- React Spring
:root { | |
--color-scale-black: hsl(0, 0%, 3.5%); | |
--color-scale-white: #ffffff; | |
--color-scale-gray-1: hsl(0, 0%, 8.5%); | |
--color-scale-gray-2: hsl(0, 0%, 11.0%); | |
--color-scale-gray-3: hsl(0, 0%, 13.6%); | |
--color-scale-gray-4: hsl(0, 0%, 15.8%); | |
--color-scale-gray-5: hsl(0, 0%, 17.9%); | |
--color-scale-gray-6: hsl(0, 0%, 20.5%); | |
--color-scale-gray-7: hsl(0, 0%, 24.3%); |
From creator of Popmotion, Pose and Framer Motion. For React, use Framer Motion.
import React from "react"; | |
type ReducerWithOptionalAction<S> = (prevState: S, action?: S) => S; | |
type ReducerStateWithOptionalAction<S> = React.ReducerState<ReducerWithOptionalAction<S>>; | |
type DispatchWithOptionalAction<S> = React.Dispatch<S> & React.DispatchWithoutAction; | |
type ReducerValueWithOptionalAction<S> = [ | |
ReducerStateWithOptionalAction<S>, | |
React.DispatchWithOptionalAction<S>, | |
]; | |
import { json, ActionFunction, useActionData, Form } from "remix"; | |
import { z } from "zod"; | |
// This type infer errors from a ZodType, as produced by `flatten()` of a parsed schema. | |
type inferSafeParseErrors<T extends z.ZodType<any, any, any>, U = string> = { | |
formErrors: U[]; | |
fieldErrors: { | |
[P in keyof z.infer<T>]?: U[]; | |
}; | |
}; |
[profile.release] | |
opt-level = "z" | |
lto = true | |
codegen-units = 1 | |
panic = "abort" |
function BetterFixedLazyExample({ lazyValue }) { | |
// Initialize with null value. | |
const myRef = useRef(null); | |
useLayoutEffect(() => { | |
console.log(myRef.current); // => HTMLDivElement DOM node | |
}, []); | |
// Make sure the ref setter is not blocked by conditionals. | |
return ( |
import React from 'react'; | |
import { createBrowserHistory } from 'history'; | |
export const historyContext = React.createContext(null); | |
const HistoryContextProvider = historyContext.Provider; | |
// This is initialized at the time the file/module is imported, and not on component mount. | |
const history = createBrowserHistory(); | |
export function History(props) { |
A list of cheap-ish fonts, that doesn't put a dent in my wallet.