dynamic-react-helmet
v1.0.5
Published
A lightweight React library for dynamic title and meta description updates.
Maintainers
Readme
dynamic-react-helmet
A lightweight and simple SEO helper for React apps — update title and meta description dynamically using a Provider, Component, or Hook.
Supports React 17, 18, 19+.
✨ Features
- 🔥 Dynamic document title
- 📝 Dynamic meta description
- 🧩 Works with React 17–19+
- 🪝 Update SEO using a hook
- 🎛️ Update SEO using a component
- 🌍 Supports SSR setups like Next.js / Custom SSR
- ⚡ Zero dependencies, tiny bundle
📦 Installation
npm install dynamic-react-helmet
# or
yarn add dynamic-react-helmet
// main.tsx or App.tsx
import { HelmetProvider } from "dynamic-react-helmet";
function App() {
return (
<HelmetProvider>
<MyRoutes />
</HelmetProvider>
);
}
export default App;
import { Helmet } from "dynamic-react-helmet";
export default function Home() {
return (
<>
<Helmet
title="Welcome to Home Page"
description="This is the homepage of our awesome website."
/>
<h1>Hello Home</h1>
</>
);
}
🛠️ Build Setup (Library Developers)
Bundled using tsup with ESM + CJS + Types.
📃 License
MIT © Ashish Tyagi
⭐ Support
If this package helped you, give it a ⭐ on npm/GitHub!
