Repository: ionic-team/ionic-framework
File: packages/vue/test/base/src/views/Overlays.vue (Vue)

Code before:
      setLoadingRef(true);
      setTimeout(() => {
        setLoadingRef(false);
        setTimeout(() => {
          setLoadingRef(true);
        }, 10);
      }, 10);
    }

    const willPresent = ref(0);
    const didPresent = ref(0);
    const willDismiss = ref(0);
    const didDismiss = ref(0);
    const ionModalWillPresent = ref(0);
    const ionModalDidPresent = ref(0);
    const ionModalWillDismiss = ref(0);
    const ionModalDidDismiss = ref(0);

    const onModalWillPresent = () => willPresent.value += 1;
    const onModalDidPresent = () => { didPresent.value += 1; setModalRef(true); }
    const onModalWillDismiss = () => willDismiss.value += 1;
    const onModalDidDismiss = () => { didDismiss.value += 1; setModalRef(false); }
    const onModalIonWillPresent = () => ionModalWillPresent.value += 1;
    const onModalIonDidPresent = () => ionModalDidPresent.value += 1;
    const onModalIonWillDismiss = () => ionModalWillDismiss.value += 1;
    const onModalIonDidDismiss = () => ionModalDidDismiss.value += 1;

    return {
      onModalWillPresent,
      onModalDidPresent,
      onModalWillDismiss,
      onModalDidDismiss,
      onModalIonWillPresent,
      onModalIonDidPresent,
      onModalIonWillDismiss,
      onModalIonDidDismiss,
      willPresent,
      didPresent,
      willDismiss,
      didDismiss,
      ionModalWillPresent,
      ionModalDidPresent,
      ionModalWillDismiss,
      ionModalDidDismiss,
      changeLoadingProps,
      overlayProps,
      present,
      componentType,
      presentationType,
      actionSheetButtons,
      alertButtons,

Review comment (suggestion):
```suggestion
    const onIonModalWillPresent = () => ionModalWillPresent.value += 1;
    const onIonModalDidPresent = () => ionModalDidPresent.value += 1;
    const onIonModalWillDismiss = () => ionModalWillDismiss.value += 1;
    const onIonModalDidDismiss = () => ionModalDidDismiss.value += 1;
```

Nit

Code after:
          break;
        case "modal":
          controller ? openModal() : setModalRef(true);
          break;
        case "popover":
          controller ? openPopover(ev) : setPopoverRef(true, ev);
          break;
        default:
          break;
      }
    }

    const changeLoadingProps = () => {
      setLoadingRef(true);
      setTimeout(() => {
        setLoadingRef(false);
        setTimeout(() => {
          setLoadingRef(true);
        }, 10);
      }, 10);
    }

    const willPresent = ref(0);
    const didPresent = ref(0);
    const willDismiss = ref(0);
    const didDismiss = ref(0);
    const ionModalWillPresent = ref(0);
    const ionModalDidPresent = ref(0);
    const ionModalWillDismiss = ref(0);
    const ionModalDidDismiss = ref(0);

    const onModalWillPresent = () => willPresent.value += 1;
    const onModalDidPresent = () => { didPresent.value += 1; setModalRef(true); }
    const onModalWillDismiss = () => willDismiss.value += 1;
    const onModalDidDismiss = () => { didDismiss.value += 1; setModalRef(false); }
    const onIonModalWillPresent = () => ionModalWillPresent.value += 1;
    const onIonModalDidPresent = () => ionModalDidPresent.value += 1;
    const onIonModalWillDismiss = () => ionModalWillDismiss.value += 1;
    const onIonModalDidDismiss = () => ionModalDidDismiss.value += 1;

    return {
      onModalWillPresent,
      onModalDidPresent,
      onModalWillDismiss,
      onModalDidDismiss,
      onIonModalWillPresent,
      onIonModalDidPresent,
      onIonModalWillDismiss,
      onIonModalDidDismiss,
      willPresent,
      didPresent,