How to use the wampy/build/wampy.min function in wampy

To help you get started, we’ve selected a few wampy 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 9inevolt / betterdgg / chrome / lib / service.js View on Github external
chrome.runtime.onConnect.addListener(function(port) {
    var wamp = new Wampy(address, {
        realm: 'bdgg',
        onConnect: function() {
            //console.log('wamp connected');
        },
        onError: function(e) { console.error('wamp error: ' + e); }
    });

    wamp.subscribe('bdgg.flair.refresh', {
        onSuccess: function() {
            //console.log('successfully subscribed');
        },
        onError: function(err) { console.error('subscription error: ' + err); },
        onEvent: function(data) {
            //console.log('refresh: ' + data);
            postUsers(data.users);
        }

wampy

Simple WAMP (WebSocket Application Messaging Protocol) Javascript implementation

MIT
Latest version published 3 months ago

Package Health Score

78 / 100
Full package analysis