How to use the @pluginjs/factory.Initializer function in @pluginjs/factory

To help you get started, we’ve selected a few @pluginjs/factory examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github pluginjs / pluginjs / modules / initializer / src / main.js View on Github external
get(plugin) {
    if (hasPlugin(plugin)) {
      return function(element, options = {}) {
        initializePlugin(plugin, element, options)
      }
    }
    return null
  },

  has(plugin) {
    return hasPlugin(plugin)
  }
}

Pj.Initializer = Initializer

export default Initializer

@pluginjs/factory

A workflow for modern frontend development.

GPL-3.0
Latest version published 2 years ago

Package Health Score

46 / 100
Full package analysis

Similar packages