Wamp Low-level Decorators

wamp() decorator

App = wamp(MyComponent, options = {});

Presentational Component

Counter.jsx

import React from 'react';

import {wamp} from 'simpl-react/lib/decorators/wamp';


const App = function App() {
  return (
    <div>
      <h3>My Amazing App</h3>
    </div>
  );
};

export default wamp({
  authid: USER_SIMPL_ID,
  password: 'nopassword',
  url: 'ws://localhost:8080/ws',
  prefixes: {
    model: CROSSBAR_ROOT_TOPIC,
  },
})(App);
Options