Skip to content
This repository was archived by the owner on Feb 22, 2024. It is now read-only.
This repository was archived by the owner on Feb 22, 2024. It is now read-only.

Error: Required is not defined #132

@randalfez

Description

@randalfez

Hi im newbie to a programming and here I was trying to use the code given in the github which is :
var ws = require('ws');
var LiveApi = require('binary-live-api').LiveApi;

var api = new LiveApi({ websocket: ws, appId: my_id });
api.authorize('mytoken');
api.events.on('authorize', function(data) {
api.getPortfolio();
});
api.events.on('portfolio', function(data) {
console.log(data);
});

but then i see this error which is saying
Uncaught ReferenceError: require is not defined

can anyone explain to me whats the error means? thank you

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions