Hello everyone,
I am trying to use BokehJS inside an angular app, and I am failing miserably. Please note that I am not familiar at all with Angular and front-end technologies in general, so I’m probably in way over my head. Any help would be greatly appreciated.
I have written a Python script that generates a JSON plot with bokeh.embed.json_item
. I am now attempting to use BokehJS to display the plot where I want it to appear in the angular app.
To do so I have installed this node package.
Then I have added the following line to the .ts
file of my Angular component :
import embed from "@bokeh/bokehjs";
But this prevents the application from compiling, with the following errors :
ERROR in node_modules/@bokeh/bokehjs/build/js/types/core/properties.d.ts(2,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/core/properties.d.ts(2,31): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/core/view.d.ts(1,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/core/view.d.ts(1,31): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/index.d.ts(3,10): error TS1005: 'from' expected.
node_modules/@bokeh/bokehjs/build/js/types/index.d.ts(3,13): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/index.d.ts(3,19): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/index.d.ts(3,24): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/index.d.ts(4,10): error TS1005: 'from' expected.
node_modules/@bokeh/bokehjs/build/js/types/index.d.ts(4,13): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/index.d.ts(4,22): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/index.d.ts(4,27): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/index.d.ts(5,10): error TS1005: 'from' expected.
node_modules/@bokeh/bokehjs/build/js/types/index.d.ts(5,13): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/index.d.ts(5,22): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/index.d.ts(5,27): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/ranges/data_range1d.d.ts(6,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/ranges/data_range1d.d.ts(6,27): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/button_tool.d.ts(6,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/button_tool.d.ts(6,38): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(10,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(10,30): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(11,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(11,35): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(12,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(12,36): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(13,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(13,33): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(14,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(14,34): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(15,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(15,30): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(16,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(16,36): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(17,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(17,36): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(18,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(18,37): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(19,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(19,38): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(20,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(20,34): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(21,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(21,32): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(22,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(22,31): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(23,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(23,31): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(24,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(24,31): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(25,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(25,32): error TS1005: ';' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(26,13): error TS1005: '=' expected.
node_modules/@bokeh/bokehjs/build/js/types/models/tools/tool.d.ts(26,31): error TS1005: ';' expected.
Could you please give me a few pointers to help me understand where I took a wrong turn ?