Untitled

mail@pastecode.io avatar
unknown
javascript
a year ago
656 B
3
Indexable
Never
import { FC } from "react";
import { Helmet, HelmetProvider } from "react-helmet-async";

interface IProps {
  title?: string;
  titleTemplate?: string;
  description?: string;
}

const SEO: FC<IProps> = ({ title, titleTemplate, description }) => {
  return (
    <HelmetProvider>
      <Helmet>
        <meta charSet="utf-8" />
        <title>
          {title} - {titleTemplate}
        </title>
        <meta name="description" content={description} />
      </Helmet>
    </HelmetProvider>
  );
};

SEO.defaultProps = {
  title: "HRM",
  titleTemplate: "Human Resources Management",
  description: "Human Resources Management",
};

export default SEO;