mapToJSObj static method

Object mapToJSObj(
  1. Map? a
)

Implementation

static Object mapToJSObj(Map<dynamic, dynamic>? a) {
  var object = js.newObject();

  if (a == null) {
    return object;
  }

  a.forEach((k, v) {
    var key = k.toString();
    var value = _dartValueToJs(v);

    js.setProperty(object, key, value);
  });
  return object;
}