toSlot method

void toSlot(
  1. int id, {
  2. bool? lazy,
})

Mounts the widget in the specified slot.

Implementation

void toSlot(int id, {bool? lazy}) {
  Element? slot = document.querySelector(slotQuery + id.toString());
  if (slot == null) return;

  if (lazy == true) {
    initializeLazyLoading(slot);
  } else {
    initialize(slot, true);
  }
}