Include dygraphs in Jekyll-run site from R -
is possible include dygraphs chart or of other js-object supported htmlwidgets.org jekyll-run site r?
i've tried different variants (rmd -> md or rmd -> html) no success. best outcome have, dyghraphs included html-code doesn't show on page (example: http://quantviews.github.io/dygraphs-test/). there working examples of jekyll-run site dygraphs included rmd-files?
i think jekyll skipping "libs" directory that's in _posts folder. (i'm pretty sure it's designed not process sub directories under "_posts".) fix move libs folder , update links point new location. example:
move "_posts/libs" folder 1 directory it's sitting next "_posts".
add "/" front of urls
<script src="libs/...
links call docroot. should like:<script src="/libs/...
.add "/" front of urls
<link href="libs/...
links call docroot. should like:<link href="/libs/....
.
that's main fix. but, there bug too. in _posts/2015-05-15-dygraphs-test.html
file, there call to:
<script src="libs/dygraphs-binding-0.4.1/dygraphs.js"></script>
but version 'dygraphs-binding' version in current libs directory 0.4.3. tried changing directory name , worked me. (i.e. "/libs/dygraphs-binding-0.4.3/dygraphs.js" becomes "libs/dygraphs-binding-0.4.1/dygraphs.js"). better line up, @ least working.
Comments
Post a Comment