observablehq / framework

A static site generator for data apps, dashboards, reports, and more. Observable Framework combines JavaScript on the front-end for interactive graphics with any language on the back-end for data analysis.
https://observablehq.com/framework/
ISC License
2.58k stars 125 forks source link

document Inputs.bind #1106

Open Fil opened 8 months ago

Fil commented 8 months ago

see https://talk.observablehq.com/t/how-to-use-div-to-customize-inputs-positions-in-framework/8948/6 and https://observablehq.observablehq.cloud/pangea/support/inputs-bind

mbostock commented 8 months ago

As mentioned in the forum post, it is demonstrated under inline expressions, and in some cases you can avoid the complexity of Inputs.bind by using inline expressions. As I wrote:

Inputs.form or Inputs.bind are in some ways workarounds for the restrictive nature of Observable notebooks where each cell can only display one thing and define one named value. In Observable Framework, code blocks can define and display as many things as you like, and using interpolated expressions, you can display content anywhere, not just at the top level.