selected method

Option selected(
  1. bool boolean
)

If present, this attribute indicates that the option is initially selected. Read more...

Implementation

Option selected(bool boolean) {
  if (boolean && node.attrs != null) {
    VirtualAttr attr = VirtualAttr('selected', '');
    node.attrs!.add(attr);
  }
  return this;
}