working on plotly/interact fix
This commit is contained in:
parent
596ca08446
commit
901115ed10
@ -12,12 +12,24 @@ function _initialize_backend(::PlotlyBackend; kw...)
|
|||||||
|
|
||||||
_js_code = open(readall, _js_path, "r")
|
_js_code = open(readall, _js_path, "r")
|
||||||
|
|
||||||
|
# _js_script = """
|
||||||
|
# <script type="text/javascript">
|
||||||
|
# require=requirejs=define=undefined;
|
||||||
|
# </script>
|
||||||
|
# <script type="text/javascript">
|
||||||
|
# $(_js_code)
|
||||||
|
# </script>
|
||||||
|
# """
|
||||||
|
|
||||||
|
# borrowed from https://github.com/plotly/plotly.py/blob/2594076e29584ede2d09f2aa40a8a195b3f3fc66/plotly/offline/offline.py#L64-L71 c/o @spencerlyon2
|
||||||
_js_script = """
|
_js_script = """
|
||||||
<script type="text/javascript">
|
<script type='text/javascript'>
|
||||||
require=requirejs=define=undefined;
|
define('plotly', function(require, exports, module) {
|
||||||
</script>
|
|
||||||
<script type="text/javascript">
|
|
||||||
$(_js_code)
|
$(_js_code)
|
||||||
|
});
|
||||||
|
require(['plotly'], function(Plotly) {
|
||||||
|
window.Plotly = Plotly;
|
||||||
|
});
|
||||||
</script>
|
</script>
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user