-
Hello everyone, I am trying to display a plot on one of my pages. Everything works for me on localhost, but not on the web. I have tried everything and I have searched a lot for documentation but I am not able to fix it. I leave below all the code and schematics: layouts/shortcodes/plotly.html Thank you very much! CODE:
layouts/shortcodes/load-plotly.html
layouts/partials/head/head.html
content/es/docs/y/x.md
static/global_map_counts.json
|
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
Hello, I think that the problem I have is related to CSP: Thank you! |
Beta Was this translation helpful? Give feedback.
-
Hello again, I'm sure all my problems come from CSP. I would like to be able to use the plotly graphics, as stated in my first message and at the same time in a secure way for my website. How could I set it all up? Thank you very much |
Beta Was this translation helpful? Give feedback.
-
If you trust the external plotly script, you could add it to the Content-Security-Policy in Note 1) Laboratory could help you with remaining CSP issues:
Note 2) Doks uses npm for central dependency management. You could also install the Plotly npm package (recommended method) |
Beta Was this translation helpful? Give feedback.
If you trust the external plotly script, you could add it to the Content-Security-Policy in
./layouts/index.headers
:script-src 'self' https://cdn.plot.ly/plotly-latest.min.js;
Note 1) Laboratory could help you with remaining CSP issues:
Note 2) Doks uses npm for central dependency management. You could also install the Plotly npm package (recommended method)