rival-black
rival-black2y ago

CreateButton custom title

Can I give the CreateButton a custom title instead of just "Create"
3 Replies
kapa.ai
kapa.ai2y ago
Hi @.chasel. I'm kapa.ai, your friendly support bot. I will try to answer your question by searching through the knowledge base. :wave: ---------------------- Yes, you can give the Create component a custom title. This can be done by passing the title prop to the Create component. If you don't pass the title prop, it uses "Create" prefix and singular resource name by default. Here is an example:
import { Create } from "@refinedev/antd";

const PostCreate: React.FC = () => {
return (
<Create title="Custom Title">
<p>Rest of your page here</p>
</Create>
);
};
import { Create } from "@refinedev/antd";

const PostCreate: React.FC = () => {
return (
<Create title="Custom Title">
<p>Rest of your page here</p>
</Create>
);
};
In this example, "Custom Title" is the title that will be displayed. Replace "Custom Title" with your desired title. Source: Refine Documentation (https://refine.dev/docs/api-reference/antd/components/basic-views/create) ---------------------- Note: you can ask me a follow up question by @ mentioning me again :speech_balloon: ----------------------
kapa.ai
kapa.ai2y ago
<@196423433930670080> kapa.ai is still learning and improving, please let us how it did by reacting below
harsh-harlequin
harsh-harlequin2y ago
<CreateButton>
Custom Title
</CreateButton>
<CreateButton>
Custom Title
</CreateButton>

Did you find this page helpful?