src method

Script src(
  1. String url, {
  2. bool? removeIf,
})

This attribute specifies the URI of an external script; this can be used as an alternative to embedding a script directly within a document. Read more...

Implementation

Script src(String url, {bool? removeIf}) {
  if (removeIf != true && node.attrs != null) {
    VirtualAttr attr = VirtualAttr('src', url);
    node.attrs!.add(attr);
  }
  return this;
}