trixta-js-core
  • Overview
  • Installation
  • Quick Start
  • Reference
    • Types
      • Action Related Types
      • Reaction Related Types
      • Other Types
    • Methods
      • Reactions
        • submitTrixtaReactionResponse
        • clearTrixtaReactionResponse
        • clearTrixtaReactionRequestStatus
      • Actions
        • submitTrixtaActionResponse
        • clearTrixtaActionResponse
        • clearTrixtaActionRequestStatus
      • updateTrixtaRole
      • updateTrixtaRoles
      • removeTrixtaRole
      • connectTrixta
      • signoutTrixta
    • Saga Methods
      • respondToTrixtaReactionEffectSaga
      • listenForTrixtaReactionResponse
    • Components
      • Reactions
        • TrixtaReactionComponent
        • RespondToReactionComponent
        • RespondToReactionsComponent
        • TrixtaReactionResponseComponent
      • Actions
        • TrixtaActionComponent
        • TrixtaActionResponseComponent
      • TrixtaAuthComponent
    • Hooks
      • Reactions
        • useTrixtaReaction
        • useRespondToReactionEffect
        • useRespondToReactionResponse
      • Actions
        • useTrixtaAction
      • useTrixtaActionReaction
      • useTrixtaSpace
      • useTrixtaRoles
      • useTrixtaAuth
      • useTrixtaAccess
      • useTrixtaRoleUnmount
    • Redux Selectors
      • Reaction Related Selectors
      • Action Related Selectors
      • Other Selectors
    • Trixta Reducer
    • Trixta Space
    • Trixta Interactions
Powered by GitBook
On this page
  • Options
  • Returns

Was this helpful?

Export as PDF
  1. Reference
  2. Hooks

useTrixtaAccess

A react hook that will return true if the given roleName has access.

import { useTrixtaAccess } from '@trixtateam/trixta-js-core';
const hasAccess = useTrixtaAccess({ roleName });

Options

  • roleName : string

    • Trixta role name

Returns

  • boolean

    • Will be true if the roleName mentioned above has access.

PrevioususeTrixtaAuthNextuseTrixtaRoleUnmount

Last updated 2 years ago

Was this helpful?

Copyright (c) 2020 Trixta Inc