sppagecontextinfo
TypeScript icon, indicating that this package has built-in type declarations

1.0.7 • Public • Published

sppagecontextinfo

SharePoint page context object for classic and modern pages

Description

This package allows you to access useful SharePoint page context info object no matter if it is classic or modern site.

Installation

npm i sppagecontextinfo

Usage

Use SPPageContextInfo.get method to access _spPageContextInfo object. Context object is returned asynchronously with Promise.

import { SPPageContextInfo } from 'sppagecontextinfo';
SPPageContextInfo.getContext().then(context=>{
  console.log(context.webAbsoluteUrl);
});

Package Sidebar

Install

npm i sppagecontextinfo

Weekly Downloads

20

Version

1.0.7

License

MIT

Unpacked Size

14.3 kB

Total Files

16

Last publish

Collaborators

  • tomaszoida