cleaner integration of pidgy
& voila
¤
pidgy
works great with widgets, so it should rock with voila
.
the default display for pidgy does NOT use widgets by default, the author would have to opt into widgets in development.
however, if we detect that voila
is driving our notebook then we should use the pidgy.displays.IPyWidgetsHtml
display.
- activate
pidgy
%reload_ext pidgy
%reload_ext pidgy
## the cookies demo
the cookies demo is inspired by the original [tanglejs](http://worrydream.com/Tangle/).
the cookies demo¤
the cookies demo is inspired by the original tanglejs.
- run the demo
---
when you eat {{cookies.value}} cookies you consume {{cookies.value * 75}} calories.
<div hidden="">
display(cookies:=IntSlider(3, description="cookies"))
</div>
---
when you eat 3 cookies you consume 225 calories.
display(cookies:=IntSlider(3, description="cookies"))
## state information
the display class in this verison is {{shell.weave.template_cls}}
because voila is{% if not pidgy.weave.is_voila() %} not{% endif %} running.
state information¤
the display class in this verison is