surround method

String surround(
  1. dynamic surround, {
  2. int doFor = 1,
  3. bool doIf = true,
  4. String between = "",
})

Implementation

String surround(
  surround, {
  int doFor = 1,
  bool doIf = true,
  String between = "",
}) =>
    applyFor(
      doIf == true && surround != null ? doFor : 0,
      (s) => s
          .pre(
            surround,
            between: between,
          )
          .post(
            surround,
            between: between,
          ),
    );