Skip to content

Instantly share code, notes, and snippets.

@metasoarous
Created November 5, 2020 00:44
Show Gist options
  • Save metasoarous/482d6b65f0b29afc8a1621078ffc2bca to your computer and use it in GitHub Desktop.
Save metasoarous/482d6b65f0b29afc8a1621078ffc2bca to your computer and use it in GitHub Desktop.
Vega embed height bug demo
<html>
<head>
<meta charset="UTF-8" />
<title>Oz document</title>
<meta content="Oz document" name="description" />
<meta content="" name="keywords" />
<meta content="width=device-width, initial-scale=1" name="viewport" />
<script src="https://cdn.jsdelivr.net/npm/vega@5.17.0" type="text/javascript"></script><script src="https://cdn.jsdelivr.net/npm/vega-lite@4.17.0" type="text/javascript"></script><script src="https://cdn.jsdelivr.net/npm/vega-embed@6.12.2" type="text/javascript"></script><script src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/MathJax.js?config=TeX-MML-AM_CHTML" type="text/javascript"></script>
</head>
<body>
<div>
<h1>A tiny Oz document</h1>
<h2>Look ye, and behold</h2>
<div>
<p>There should be a final paragraph after the viz below, but you have to scroll <i>way</i> down to see it</p>
</div>
<div>
<div id="viz-75e7437f-1da7-4c65-8cb0-98fcc9d96bfc"></div>
<script type="text/javascript">vegaEmbed('#viz-75e7437f-1da7-4c65-8cb0-98fcc9d96bfc', {"data":{"values":[{"a":2,"b":3},{"a":5,"b":2},{"a":7,"b":4}]},"mark":"point","width":400,"encoding":{"x":{"field":"a","type":"quantitative"},"y":{"field":"b","type":"quantitative"}}}, {"mode":"vega-lite"});</script>
</div>
<p>Did you miss me?</p>
</div>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment