Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More

@annotation-studio/plugin-core

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@annotation-studio/plugin-core

Annotation studio core plugin

  • 1.0.0-pr.b8f203c7
  • npm
  • Socket score

Version published
Weekly downloads
26
increased by62.5%
Maintainers
1
Weekly downloads
 
Created

Annotation Studio - Core plugin

This is the state behind the other components.

Usage

To use the plugin you need to add it as a dependency:

$ npm i @annotation-studio/plugin-core --save-dev

Then in your code (ES6 in this example)

import CorePlugin from '@annotation-studio/plugin-core';

const core = CorePlugin(
  document.getElementById('myContainer'),
  {
    resourceTemplates: '...',
    manifest: '...',
    canvas: '...',
    elucidateServer: '...',
  }
);

core.then(store => {
  // this is called whenever the store changes
  store.subscribe(() => {
    // This is how to get the state
    const state = store.getState();
    // You can now render things, dispatch actions etc.
  })
})

Resource templates:

[todo add link to resource template model]

FAQs

Package last updated on 17 May 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts