nuts 2.1.4 copy "nuts: ^2.1.4" to clipboard
nuts: ^2.1.4 copied to clipboard

Nuts and bolts for building cross-platform UI (HTML, Flutter, CLI) using Dart. Also screw frameworks (React, Vue, Angular).

nuts #

Nuts and bolts for building cross-platform UI (HTML, Flutter, CLI) using Dart. Also screw frameworks (React, Vue, Angular).

Example #

class Counter implements Component {
  @override
  String key;

  int count = 0;

  @override
  View makeView() {
    Box ret;
    ret = Box(children: [
      TextField('Count: $count', key: 'info'),
      HBox(children: [
        Button(
            text: 'Increment',
            onClick: () {
              ret.getByKey<TextField>('info').text = 'Count: ${++count}';
            }),
        Button(
            text: 'Decrement',
            onClick: () {
              ret.getByKey<TextField>('info').text = 'Count: ${--count}';
            }),
      ]),
    ]);
    return ret;
  }
}

void main() {
  querySelector('#output').append(defaultRenderers.render(Counter()));
}
0
likes
30
pub points
0%
popularity

Publisher

unverified uploader

Nuts and bolts for building cross-platform UI (HTML, Flutter, CLI) using Dart. Also screw frameworks (React, Vue, Angular).

Repository (GitHub)
View/report issues

License

BSD-3-Clause (LICENSE)

Dependencies

collection, observable_ish

More

Packages that depend on nuts