pyvis icon indicating copy to clipboard operation
pyvis copied to clipboard

The js / css resources are not read from local drive but from cdn with cdn_resources="in_line"

Open fohrloop opened this issue 2 years ago • 1 comments

Using pyvis 0.3.2

Steps to reproduce:

# script.py
from pyvis.network import Network
nt = Network(
    cdn_resources="in_line",
)
nt.show('network.html', notebook=False)

The output draws content from

niko@niko-ubuntu:~/tmp/pyvis_tests$ cat network.html | grep 'href=\"http\|src=\"http' -C 5
</center>

<!-- <link rel="stylesheet" href="../node_modules/vis/dist/vis.min.css" type="text/css" />
<script type="text/javascript" src="../node_modules/vis/dist/vis.js"> </script>-->
        <link
          href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css"
          rel="stylesheet"
          integrity="sha384-eOJMYsd53ii+scO/bJGFsiCZc+5NDVN2yr8+0RDqr0Ql0h+rP48ckxlpbzKgwra6"
          crossorigin="anonymous"
        />
        <script
          src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js"
          integrity="sha384-JEW9xMcG8R+pH31jmWH6WWP0WintQrMb4s7ZOdauHnUtxwoG2vI5DkLtS3qm9Ekf"
          crossorigin="anonymous"
        ></script>

fohrloop avatar May 03 '23 07:05 fohrloop

Closely related to: https://github.com/WestHealth/pyvis/issues/228 Related PR: https://github.com/WestHealth/pyvis/pull/201

fohrloop avatar May 03 '23 07:05 fohrloop