"use strict";
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
const React = require("react");
const useDidUpdate = require("../use-did-update/use-did-update.cjs");
function useLogger(componentName, props) {
  React.useEffect(() => {
    console.log(`${componentName} mounted`, ...props);
    return () => console.log(`${componentName} unmounted`);
  }, []);
  useDidUpdate.useDidUpdate(() => {
    console.log(`${componentName} updated`, ...props);
  }, props);
  return null;
}
exports.useLogger = useLogger;
