Skip to content

Latest commit

 

History

History
35 lines (26 loc) · 1.02 KB

README.md

File metadata and controls

35 lines (26 loc) · 1.02 KB

@nextcloud/auth

REUSE status npm Documentation

Nextcloud helpers related to authentication and the current user

Install

npm install @nextcloud/auth --save
yarn add @nextcloud/auth

Usage

For detailed information check the package documentation.

One example usage to get the current user:

import { getCurrentUser } from '@nextcloud/auth'

const user = getCurrentUser()

if (user.isAdmin) {
  // do something
}