import { useRef } from "react";

/**
 * 在组件首次创建时调用
 */
export function useCreate(cb: Function) {
  const initialized = useRef(false);
  if (!initialized.current) {
    initialized.current = true;
    cb();
  }
}
