moodymudskipper / flow

View and Browse Code Using Flow Diagrams
https://moodymudskipper.github.io/flow/
Other
397 stars 26 forks source link

flow in markdown quarto #178

Open moodymudskipper opened 1 month ago

moodymudskipper commented 1 month ago

For some reason I never got it quite right, but I think I was hoping that the default printing would include the diagram in the doc, I think we might have out = "report" that uses knits::include_graphics() on a temp png file. I don't remember why it was a challenge to recognise that we're knitting and adapt the behavior, there should be an env variable. Let's have another pass on this.

moodymudskipper commented 1 month ago

From opt::opt$knitr$ I found getOption("knitr.in.progress"))

opt::opt$knitr$knitr.in.progress
#> Call `opt$knitr$knitr.in.progress()` to get and `opt$knitr$knitr.in.progress(value)` to set.
#> This option is used by : `` `knitr::spin_child()` ``

It seems that it's not properly documented but further research indicates that Yihui recommends it for some cases: https://github.com/yihui/knitr/issues/926