Page Contents

Home > @loopback/authentication > AuthenticationBindings > USER_PROFILE_FACTORY

AuthenticationBindings.USER_PROFILE_FACTORY variable

Key used to bind a user profile factory to the context for any consumer to use when they need to convert a user object into a slimmer user profile object

Signature:

USER_PROFILE_FACTORY: BindingKey<UserProfileFactory<any>>

Example

server
  .bind(AuthenticationBindings.USER_PROFILE_FACTORY)
  .to(myUserProfileFactory);