I have setup authentication for nebular using all of their components and used NbPasswordAuthStrategy
as authentication strategy.
The register component currently has following inputs,
But my API requires me to have First Name and Last Name instead of Full Name. How do I go about configuring the framework so that it fits my custom needs?
I have researched on how to do this, but came up with no results. Neither the NbPasswordAuthStrategy
setup has any way to customise the form nor there is an example provided for customising the form.
My Authentication config looks like this
{
strategies: [
NbPasswordAuthStrategy.setup({
name: 'email',
token: {
class: NbAuthJWTToken,
key: 'token'
},
baseEndpoint: 'api',
login: {
endpoint: '/auth/login',
redirect: {
success: '/pages/dashboard',
failure: null,
},
},
register: {endpoint: '/auth/register'},
}),
],
forms: {
logout: {
strategy: 'email'
}
},
}
You can't customize auth components via auth module configuration instead you need to extend and customize Nebular auth components. Here is a guide.