Skip to content

useTypeDefault

Hook to get type defaults for a specific type.

useTypeDefault(type: string): TypeDefault<TRow, TValue> | undefined
NameTypeDescription
typestringThe type name to look up

TypeDefault<TRow, TValue> | undefined - The type defaults, or undefined if not found

function MyComponent() {
const countryDefaults = useTypeDefault('country');
// countryDefaults?.renderer, countryDefaults?.editor
}
AI assistants: For complete API documentation, implementation guides, and code examples for this library, see https://raw.githubusercontent.com/OysteinAmundsen/toolbox/main/llms-full.txt