react-seo-fix
v1.0.2
Published
Add full SEO optimisation to any React/Vite SPA in one command. Adds pre-rendering, per-page meta tags, sitemap, and robots.txt.
Maintainers
Readme
react-seo-fix
Add full SEO optimisation to any React/Vite SPA in one command.
Installs pre-rendering, per-page meta tags, sitemap.xml, and robots.txt — making your site fully visible to Google, AI search engines, and social media previews.
Usage
Open the terminal in your project folder and run:
npx react-seo-fixAnswer 3 questions (your domain, site title, and page routes), and the tool does the rest.
What it installs
src/entry-server.tsx— server-side rendering entry pointscripts/prerender.mjs— generates pre-rendered HTML for every page at build timescripts/generate-sitemap.mjs— generates sitemap.xmlpublic/robots.txt— allows all search engines and AI crawlerspublic/sitemap.xml— initial sitemapnetlify.toml— Netlify deployment configuration
What it updates
package.json— adds thebuildscript pipeline andreact-helmet-asyncdependencyvite.config.ts— adds build configuration for SSR
After running
- Add
<Helmet>tags to each page in your app (see the full guide at reactseo.co.uk) - Run
npm run buildto test the build locally - Push to GitHub and deploy to Netlify
- Submit your sitemap to Google Search Console
