Parameters
DetailPageProps<T, C, U>Props to configure the DetailPage component.
stringThe name of the entity. If not provided, it will be inferred from the query document.
stringA unique identifier for the page.
AnyRouteThe TanStack Router route used to navigate to this page.
(entity: ResultOf<T>[EntityField]) => stringThe title of the page.
TThe query document used to fetch the entity.
CThe mutation document used to create the entity.
UThe mutation document used to update the entity.
(entity: ResultOf<T>[EntityField]) => VariablesOf<U>['input']A function that sets the values for the update input type based on the entity.
NoInfer<(params: Record<string, string>) => Partial<VariablesOf<C>['input']>>v3.8.0A function that sets the starting values for the form when creating a new entity, based on the route params. It runs again only when the route params change. The starting values count as unsaved changes, so the submit button is enabled and leaving the page asks the user to confirm.
Architecture reviews, custom plugin work, migrations, ongoing support. Get a hand from the team that builds Vendure.
Talk to the team