Openfort Kit Button
To use the Openfort Kit Button, you will need to use the OpenfortKitButton
component. This component will render a button that will open the Openfort login screen when clicked.
import { OpenfortKitButton } from '@openfort/openfort-kit';
function App() {
return (
<div>
<OpenfortKitButton />
</div>
);
};
This button will use the default configuration of the Openfort Kit, but you can customize the theme properties of the button.
There are other customization properties:
showAvatar
: Show the avatar of the usershowBalance
: Show the balance of the userlabel
: The label of the button when the user is not connected
The OpenfortKitButton
component also provides a onClick
callback that will be called when the user clicks the button.