import { useApi } from './api.mjs';

/**
 * Returns the `I18nTranslate` interface used to translate strings.
 */
function useTranslate() {
  const api = useApi();
  return api.i18n.translate.bind(api.i18n);
}

export { useTranslate };
