Socket
Socket
Sign inDemoInstall

vue-kuzzle

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

vue-kuzzle

A (very simple) Vuejs plugin shipping the Kuzzle SDK in your components


Version published
Maintainers
1
Created
Source

Vuejs Kuzzle Plugin

This plugin simply exposes the Kuzzle SDK in your Vuejs components.

Getting started

Install the plugin via

npm install vue-kuzzle

Then, in your Vuejs application, you need to register the plugin in your Vue class.

import VueKuzzle from 'vue-kuzzle';

Vue.use(VueKuzzle, options);

Where options may contain the following options.

options.backends

An object of available backends to connect to. Backends are POJOs of the following form (the example shows the default config):

options.backends = {
  local: {
    host: 'localhost',
    options: {
      port: 7512,
      sslConnection: false
    }
  }
};

The plugin will instantiate the Kuzzle SDK with the Websocket protocol, choosing among the available backends based on the process.env.VUE_APP_BACKEND environment variable. If this variable is not specified, the local backend is choosen as fallback.

Warning Don't forget to connect() your instance before performing any actions.

Accessing the Kuzzle SDK instance within the app

You'll be able to access the Kuzzle SDK instance from the components as

this.$kuzzle;

And from anywhere in your app where the Vue class is available, as

Vue.prototype.$kuzzle;

Keywords

FAQs

Package last updated on 28 Aug 2019

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc