-
-
Notifications
You must be signed in to change notification settings - Fork 139
Closed
Description
I get the error in the node repl when trying to import react-plotly using require. In the browser, the call to require('react-plotly.js')
returns undefined, though I don't any exception in the console.
Welcome to Node.js v16.13.1.
Type ".help" for more information.
> const {Plot} = require('react-plotly.js');
Uncaught ReferenceError: self is not defined
at Object.58 (/home/sphelps/tmp/test/node_modules/plotly.js/dist/plotly.js:9084:9)
at o (/home/sphelps/tmp/test/node_modules/plotly.js/dist/plotly.js:7:631)
at /home/sphelps/tmp/test/node_modules/plotly.js/dist/plotly.js:7:682
at Object.503.../constants/numerical (/home/sphelps/tmp/test/node_modules/plotly.js/dist/plotly.js:128735:10)
at o (/home/sphelps/tmp/test/node_modules/plotly.js/dist/plotly.js:7:631)
at /home/sphelps/tmp/test/node_modules/plotly.js/dist/plotly.js:7:682
at Object.1.../src/lib (/home/sphelps/tmp/test/node_modules/plotly.js/dist/plotly.js:10:11)
at o (/home/sphelps/tmp/test/node_modules/plotly.js/dist/plotly.js:7:631)
I am using the following dependencies:
"dependencies": {
"plotly.js": "^2.8.3",
"react-plotly.js": "^2.5.1"
}
Any suggestions as to what I am doing wrong?
kplatis and v0lta
Metadata
Metadata
Assignees
Labels
No labels