Sunbird Tag Manager
Library is used to create Edge Computable Tags agnostic to project, framework choice. This works like a Open Specification to enable clients to generate Tags and Evaluate these tags against a criteria from server.
Current Release Branch
master
NPM Published version (Latest)
3.9.19
NPM Package Name
@project-sunbird/sb-tag-manager
Works
Across all projects. (Framework and Tech Agnostic Library)

Installation

  1. 1.
    Install the library in the project as follows :
1
npm i @project-sunbird/sb-tag-manager
Copied!

Getting Started

  1. 1.
    Navigate to App Component (or) Equivalent module and add the following import
1
import { SBTagModule } from 'sb-tag-manager';
Copied!
  1. 1.
    Initialise the Library
1
let instance = SBTagModule.instance;
2
instance.init();
Copied!

Services

SBTagService

  1. 1.
    Tag Interface Methods
1
instance.SBTagService.pushTag({object},"prefix_string");
2
instance.SBTagService.getTags("prefix_string");
3
instance.SBTagService.getAllTags();
4
instance.SBTagService.removeTag("prefix_string");
5
instance.SBTagService.removeAll();
Copied!
Copy link
Edit on GitHub