<div dir="ltr">Hi all,<div><br></div><div>I was playing around with embeddable javascript libraries and seeing if I could make use them from a Notebook. My first attempt was to try the simplest thing possible; embed it in a markdown cell. The javascript I was trying to embed wants to both source an external file, and then use it via some local javascript code, like</div>
<div><div>   <script language="javascript" src="<a href="http://some-url/library.js">http://some-url/library.js</a>"></script></div><div>   <script language="javascript"></div>
</div><div>   ... code ...</div><div>   </script></div><div><br></div><div>In Notebook 1.x, the local code executes but throws an error about undefined variables, suggesting that the external javascript file was not loaded. Is this expected?</div>
<div><br></div><div>In Notebook 2.0, so far as I can tell, none of it executes at all.</div><div><br></div><div>Am I right in thinking that embedding Javascript into a markdown cell has been deprecated? Do I need to put it into custom.js instead? And, will I be able to source the remote file from there, or will I need to make that library local as well?</div>
<div><br></div><div>Sorry if this is a naive question, a lot of aspects of this are new to me. I'm just looking for the most straightforward and lightweight approach so I can experiment with my code.</div><div><br></div>
<div>Thanks in advance,</div><div>Clare</div></div>