Production Documentation Site: https://gopichand-virima.github.io/FeatureDocsite/
This is the official documentation website for Virima, supporting multiple versions (NextGen, 6.1.1, 6.1, 5.13) with comprehensive SEO optimization, interactive navigation, and modern user experience.
- Project Overview
- Quick Start for Writers
- Mandatory Commands
- Project Structure
- Key Files and Their Roles
- Writer Workflow
- Content Guidelines
- SEO Metadata Requirements
- Troubleshooting
This is a React-based documentation website that:
- Displays Virima documentation across multiple versions
- Provides interactive navigation with expandable sidebar
- Generates SEO-optimized pages with proper meta tags
- Creates breadcrumb navigation automatically
- Supports MDX (Markdown + JSX) for rich content formatting
β
Multi-Version Support: NextGen, 6.1.1, 6.1, 5.13
β
11 Complete Modules: Admin, ITSM, ITAM, CMDB, Discovery Scan, My Dashboard, Self Service, Program/Project Management, Risk Register, Reports, Vulnerability Management
β
SEO Optimized: Automatic sitemap generation, meta tags, structured data
β
Smart Navigation: 7-level breadcrumb hierarchy, clickable navigation
β
Automated Deployment: GitHub Actions CI/CD
β
Type-Safe: Full TypeScript implementation
β
User Feedback System: Integrated feedback survey on all documentation pages
β
Version-Aware Image Mapping: Automatic image path transformation for all versions
β
Enhanced Error Handling: Route-based error recovery with ErrorBoundary
- Framework: React 18 + TypeScript
- Build Tool: Vite 6
- Styling: Tailwind CSS
- Content Format: MDX (Markdown + JSX)
- Routing: React Router
- SEO: react-helmet-async
- Email Service: EmailJS (for feedback forms)
- Deployment: GitHub Pages
- Node.js 18 or 20 installed
- Git installed
- Basic knowledge of Markdown
- Text editor (VS Code recommended)
# 1. Clone the repository (if you haven't already)
git clone https://github.com/gopichand-virima/FeatureDocsite.git
cd FeatureDocsite
# 2. Install dependencies (first time only)
npm install
# 3. Start development server
npm run devThe site will open at http://localhost:5173
# Start development server (MANDATORY before writing)
npm run dev
# Normalize frontmatter after editing MDX files (MANDATORY before commit)
npm run normalize:frontmatter
# Build project to check for errors (MANDATORY before pushing)
npm run build# Add frontmatter to new MDX files (if missing)
npm run add:frontmatter
# Normalize all frontmatter (ensures consistency)
npm run normalize:frontmatter
# Generate sitemap (happens automatically on build)
npm run generate:sitemap# Build for production (includes sitemap generation)
npm run build
# Deploy to GitHub Pages (usually handled by GitHub Actions)
npm run deploy| Command | When to Use | What It Does |
|---|---|---|
npm run dev |
Every time you write | Starts local development server |
npm run normalize:frontmatter |
After editing MDX files | Cleans and standardizes metadata |
npm run build |
Before committing/pushing | Builds project and checks for errors |
npm run add:frontmatter |
When creating new files | Adds default frontmatter to files without it |
npm run generate:sitemap |
Before deployment | Generates sitemap.xml (auto-runs on build) |
FeatureDocsite/
βββ src/
β βββ components/ # React components (UI, layout, content)
β β βββ DocumentationLayout.tsx # Main layout with sidebar
β β βββ DocumentationContent.tsx # Content rendering + breadcrumbs
β β βββ MDXContent.tsx # MDX content renderer
β β βββ Seo.tsx # SEO meta tags component
β β βββ ErrorBoundary.tsx # Error handling
β β βββ ui/ # Reusable UI components
β β
β βββ content/ # π YOUR CONTENT GOES HERE
β β βββ 6_1/ # Version 6.1 content
β β β βββ admin_6_1/ # Admin module (223 files)
β β β βββ cmdb_6_1/ # CMDB module (37 files)
β β β βββ discovery_scan_6_1/ # Discovery Scan (355 files)
β β β βββ itsm_6_1/ # ITSM module
β β β βββ itam_6_1/ # ITAM module (101 files)
β β β βββ my_dashboard_6_1/ # My Dashboard (18 files)
β β β βββ ... # Other modules
β β β
β β βββ NG/ # NextGen content
β β βββ 6_1_1/ # Version 6.1.1 content
β β βββ 5_13/ # Version 5.13 content
β β βββ contentLoader.ts # Content loading logic
β β
β βββ config/
β β βββ seoConfig.ts # SEO configuration (canonical host, defaults)
β β
β βββ utils/
β β βββ mdxPathResolver.ts # Resolves MDX file paths
β β βββ routeBuilder.ts # Builds URL routes
β β
β βββ App.tsx # Main application (routing, state)
β βββ main.tsx # Application entry point
β
βββ scripts/ # Automation scripts
β βββ generate-sitemap.ts # Generates sitemap.xml
β βββ add-frontmatter.ts # Adds frontmatter to MDX files
β βββ normalize-frontmatter.ts # Normalizes existing frontmatter
β βββ remove-added-frontmatter.ts # Cleanup script
β
βββ public/
β βββ robots.txt # Search engine crawler rules
β βββ sitemap.xml # Generated sitemap (auto-updated)
β βββ 404.html # 404 page for GitHub Pages
β βββ images_*/ # Version-specific image folders
β βββ images_6_1/ # Version 6.1 images
β βββ images_6_1_1/ # Version 6.1.1 images
β βββ images_5_13/ # Version 5.13 images
β βββ images_ng/ # NextGen images
β
βββ .github/
β βββ workflows/
β βββ deploy.yml # Automated deployment workflow
β
βββ package.json # Project dependencies and scripts
βββ README.md # This file
Version 6.1 (Most Complete):
- Location:
src/content/6_1/ - Format:
{module}_6_1/{topic-name}_6_1.mdxor{topic-name}-6_1.mdx - Example:
src/content/6_1/cmdb_6_1/access_cmdb_6_1.mdx - Image Paths: Use
../Resources/Images/...in MDX (auto-transformed to/images_6_1/...)
NextGen:
- Location:
src/content/NG/{module}/ - Format:
{topic-name}.mdxor{topic-name}_ng.mdx - Example:
src/content/NG/my-dashboard/overview.mdx - Image Paths: Use
../Resources/Images/...in MDX (auto-transformed to/images_ng/...)
Other Versions (6.1.1, 5.13):
- Location:
src/content/{version}/{module}/ - Format:
overview.mdx(currently minimal content) - Image Paths: Use
../Resources/Images/...in MDX (auto-transformed to/images_{version}/...)
Location: src/content/{version}/{module}/
Role: Your actual documentation content
- Write documentation in Markdown format
- Add frontmatter (YAML metadata) at the top
- Use MDX for rich formatting
Example Structure:
---
title: "Page Title"
description: "Page description for SEO"
canonical: "/6_1/cmdb/cmdb/access-cmdb"
keywords:
- "virima"
- "cmdb"
- "configuration management"
lastUpdated: "2025-01-15"
---
# Page Title
Your content here...Location: src/components/DocumentationLayout.tsx
Role: Defines the sidebar navigation structure
- When to edit: Adding new sections or reorganizing navigation
- Contains
adminSections,cmdbSections, etc. - Defines the Table of Contents (TOC) hierarchy
Example:
const cmdbSections = [
{
id: 'cmdb',
label: 'CMDB',
pages: [
{ id: 'access-cmdb', label: 'Access CMDB' },
{ id: 'manage-cmdb', label: 'Manage CMDB' },
// ... more pages
]
}
];Location: src/components/FeedbackSection.tsx
Role: User feedback collection system
- When to edit: Customizing feedback questions or email configuration
- Integrated into all documentation pages automatically
- Uses EmailJS for email delivery
- Note: Configure EmailJS service IDs in the component before deployment
Role: Main application component
- Handles routing and URL parsing
- Manages version/module/section/page state
- Maps file names to page IDs
- Don't edit unless adding new module mappings
Role: Renders content and breadcrumbs
- Loads MDX content based on route
- Generates breadcrumb navigation
- Handles parent topic detection
- Don't edit unless fixing breadcrumb logic
Role: Loads and parses MDX files
- Imports all MDX files statically
- Parses frontmatter (browser-safe)
- Maps file paths to content
- Edit when: Adding new content imports
Role: Resolves MDX file paths from route parameters
- Converts URL segments to file paths
- Handles version-specific path logic
- Edit when: Adding new version or path patterns
Role: SEO configuration
- Defines canonical hostname
- Sets default meta tags
- Controls indexing rules
- Edit when: Changing canonical domain or SEO defaults
Role: Generates sitemap.xml
- Reads navigation structure
- Creates sitemap entries for all pages
- Updates lastmod dates
- Runs automatically on build
Role: Renders MDX content with image path transformation
- Automatically transforms image paths based on version
- Handles frontmatter stripping
- Provides loading and error states
- Key Feature: Version-aware image path mapping (
../Resources/Images/...β/images_{version}/...)
Role: Catches and handles React errors gracefully
- Displays user-friendly error messages
- Resets error state on route changes (allows recovery via browser back button)
- Prevents blank white screens
Role: Landing page with hero section and module cards
- Modern, premium design with white/slate color scheme
- Interactive module navigation
- Search functionality
- Updated: January 2025 with new design system
-
Create the MDX File
# Example: Adding a new CMDB topic for version 6.1 src/content/6_1/cmdb_6_1/my-new-topic-6_1.mdx -
Add Frontmatter
--- title: "My New Topic" description: "Clear description of what this page covers (150-160 characters)" canonical: "/6_1/cmdb/cmdb/my-new-topic" keywords: - "virima" - "cmdb" - "new feature" lastUpdated: "2025-01-15" --- # My New Topic Your content here...
-
Add to Navigation
- Edit
src/components/DocumentationLayout.tsx - Add the page to the appropriate section's
pagesarray - Example:
pages: [ { id: 'access-cmdb', label: 'Access CMDB' }, { id: 'my-new-topic', label: 'My New Topic' }, // Add this ]
- Edit
-
Update Content Loader (if needed)
- Edit
src/content/contentLoader.ts - Add import:
import myNewTopic from './6_1/cmdb_6_1/my-new-topic-6_1.mdx?raw'; - Add to
contentMap:'/content/6_1/cmdb_6_1/my-new-topic-6_1.mdx': myNewTopic
- Edit
-
Normalize Frontmatter
npm run normalize:frontmatter
-
Test Locally
npm run dev # Navigate to the new page in browser # Verify it loads correctly
-
Build and Verify
npm run build # Check for any errors
-
Edit the MDX File
- Open the file in
src/content/{version}/{module}/ - Make your changes
- Update
lastUpdateddate in frontmatter
- Open the file in
-
Normalize Frontmatter (if you changed metadata)
npm run normalize:frontmatter
-
Test Locally
npm run dev # Verify changes look correct -
Build Before Committing
npm run build
- Start dev server:
npm run dev - Edit MDX files in
src/content/ - Add/update frontmatter with proper metadata
- Run
npm run normalize:frontmatterafter editing - Test in browser (check navigation, breadcrumbs, content)
- Run
npm run buildto check for errors - Commit and push changes
Version 6.1:
- Use underscores or hyphens:
my-topic-6_1.mdxormy_topic_6_1.mdx - Be consistent within a module
- Match the pattern used in the module folder
NextGen:
- Use hyphens:
my-topic.mdxormy-topic_ng.mdx - Module overview files should be named
overview_ng.mdx
Important: All versions support automatic image path transformation!
In Your MDX Files:
- Use relative paths:
../Resources/Images/folder/image.png - The system automatically transforms them to version-specific paths:
- 6.1:
/images_6_1/folder/image.png - 6.1.1:
/images_6_1_1/folder/image.png - 5.13:
/images_5_13/folder/image.png - NextGen:
/images_ng/folder/image.png
- 6.1:
Example:
<!-- In your MDX file -->

<!-- Automatically becomes (for 6.1) -->
Image Folder Structure:
- Place images in
public/images_{version}/folders - Maintain the same folder structure as
Resources/Images/ - Example:
public/images_6_1/CMDB/dashboard.png
Every MDX file MUST have frontmatter:
---
title: "Page Title" # Required: 50-60 characters
description: "Page description..." # Required: 150-160 characters
canonical: "/version/module/section/page" # Required: matches URL structure
keywords: # Required: 3-10 keywords
- "virima"
- "module-name"
- "feature-name"
lastUpdated: "2025-01-15" # Required: YYYY-MM-DD format
----
Use Clear Headings
- Start with H1 (
#) for page title - Use H2 (
##) for main sections - Use H3 (
###) for subsections
- Start with H1 (
-
Keep Descriptions Concise
- 150-160 characters for SEO
- Summarize what the page covers
- Include key search terms
-
Use Consistent Formatting
- Follow existing patterns in the module
- Use code blocks for commands/examples
- Use lists for step-by-step instructions
-
Update Last Updated Date
- Change
lastUpdatedwhen content changes significantly - Format:
YYYY-MM-DD
- Change
SEO metadata helps your documentation appear in Google search results. Without proper metadata:
- Pages might not be found by search engines
- Search results show generic titles
- Lower click-through rates
- Poor search rankings
| Field | Required | Format | Example |
|---|---|---|---|
title |
β Yes | String, 50-60 chars | "Advanced Search" |
description |
β Yes | String, 150-160 chars | "Learn how to use advanced search..." |
canonical |
β Yes | URL path | "/6_1/cmdb/cmdb/access-cmdb" |
keywords |
β Yes | Array, 3-10 items | ["virima", "cmdb", "search"] |
lastUpdated |
β Yes | Date, YYYY-MM-DD | "2025-01-15" |
Format: /{version}/{module}/{section}/{page}
Examples:
/NextGen/my-dashboard/application-overview/advanced-search/6_1/cmdb/cmdb/access-cmdb/6_1/admin/discovery/client/restart-client
Rules:
- Use lowercase
- Use hyphens to separate words
- Match the actual URL structure
- No trailing slashes
- Title is clear and descriptive (50-60 chars)
- Description is unique and helpful (150-160 chars)
- Canonical URL matches route structure
- Keywords are relevant (3-10 keywords)
- Last updated date is current
- No HTML tags in title/description/keywords
- YAML syntax is correct
See README_6_1.md for detailed SEO/GEO guide with examples.
- Added: Integrated feedback form on all documentation pages
- Features:
- Thumbs up/down initial feedback
- Follow-up questions based on feedback type
- Role selection and NPS scoring
- EmailJS integration for email delivery
- Submission tracking (max 2 per session)
- Location:
src/components/FeedbackSection.tsx - Note: Configure EmailJS service IDs before deployment
- Updated: Hero section with premium white/slate design
- Features:
- Clean, modern aesthetic
- Floating service icons
- Enhanced hover effects
- Improved visual hierarchy
- Location:
src/components/HomePage.tsx
- Feature: All MDX files automatically transform image paths based on version
- How It Works:
- MDX files use:
../Resources/Images/... - System transforms to:
/images_{version}/... - Supports all versions: 6.1, 6.1.1, 5.13, NextGen
- MDX files use:
- Location:
src/components/MDXContent.tsxβtransformImagePaths() - Benefit: No manual path updates needed when moving content between versions
- Fixed: Admin module breadcrumb hierarchy
- Fixed: Section detection for nested Admin sub-modules (SACM, Discovery, Users, etc.)
- Fixed: Breadcrumb home icon now correctly navigates to homepage
- Result: Accurate breadcrumbs matching TOC structure
- Added: Route-based error state reset
- Feature: Browser back button now recovers from error pages
- Implementation: ErrorBoundary resets when route changes
- Location:
src/components/ErrorBoundary.tsx+src/App.tsx
- Added: Client-side redirect handling for deep links
- Feature: Handles 404 redirects gracefully
- Implementation: Session storage-based redirect recovery
- Location:
src/main.tsx
- Renamed: All NextGen folders/files from
_6_1to_ngsuffix - Standardized: Module overview files now use
overview_ng.mdxnaming - Cleaned: Removed duplicate folders without
_ngsuffix - Result: Consistent naming convention across NextGen content
- Added:
emailjs-comdependency for feedback forms - Updated: Vite config with EmailJS alias
- Fixed: Package lock file synchronization
- Improved: Graceful fallback for missing content
- Fixed: Error logging for expected fallbacks
- Enhanced: Version-specific path resolution
- Refactored: Admin page constants moved to shared module
- Location:
src/constants/adminPages.ts - Benefit: Prevents duplicate declarations and initialization errors
Version 6.1:
- β Complete image path transformation
- β Full Admin module sub-section support
- β Enhanced breadcrumb hierarchy
- β All modules fully documented
NextGen:
- β
Standardized
_ngnaming convention - β Image path transformation
- β Module overview standardization
- β Content replication for missing pages
All Versions:
- β Consistent image path transformation
- β Feedback survey integration
- β Enhanced error handling
- β Improved navigation experience
Solution:
- Check browser console for errors
- Verify MDX file exists in correct location
- Check that file is imported in
contentLoader.ts - Verify frontmatter syntax is correct
- Run
npm run buildto check for build errors
Solution:
- Add page to
DocumentationLayout.tsxin the appropriate section - Verify
idmatches the page ID in URL - Restart dev server:
npm run dev
Solution:
- Check that page is in correct section array in
DocumentationContent.tsx - Verify parent topic arrays include your page
- Check URL structure matches breadcrumb logic
Solution:
- Verify frontmatter is correct (run
npm run normalize:frontmatter) - Check canonical URL matches actual route
- Rebuild:
npm run build - Wait 1-7 days for Google to index (submit sitemap in Search Console)
Solution:
- Check for TypeScript errors:
npm run build - Verify all imports are correct
- Check MDX file syntax
- Ensure frontmatter YAML is valid
- Run
npm installif dependencies are missing
Solution:
- Verify images are in
public/images_{version}/folder - Check image paths in MDX use
../Resources/Images/...format - Ensure folder structure matches (e.g.,
public/images_6_1/CMDB/image.png) - Check browser console for 404 errors
Solution:
- Verify EmailJS service IDs are configured in
FeedbackSection.tsx - Check EmailJS service, template, and public key are set
- Verify
emailjs-comis installed:npm install - Check browser console for EmailJS errors
Solution:
- Verify ErrorBoundary is wrapping AppContent in
App.tsx - Check that
resetKeyprop is being passed correctly - Ensure route changes trigger ErrorBoundary reset
- Clear browser cache and try again
-
Check Documentation:
README_6_1.md- Detailed project documentationtutorials/seo-geo-management.md- SEO guidesrc/docs/- Additional documentation
-
Check Browser Console:
- Open DevTools (F12)
- Check Console tab for errors
- Check Network tab for failed requests
-
Verify File Structure:
- Ensure files are in correct folders
- Check naming conventions match patterns
- Verify imports in
contentLoader.ts
- Detailed Documentation: See
README_6_1.mdfor comprehensive project details - SEO Guide: See
tutorials/seo-geo-management.mdfor SEO best practices - Content Guidelines: See
src/content/README.mdfor content writing guidelines - Architecture: See
src/docs/architecture-diagram.mdfor system architecture
npm run dev # Start development server
npm run normalize:frontmatter # Clean frontmatter (run after editing)
npm run build # Build project (check for errors)- Content:
src/content/{version}/{module}/ - Navigation:
src/components/DocumentationLayout.tsx - Content Loader:
src/content/contentLoader.ts - SEO Config:
src/config/seoConfig.ts
- 6.1 Files:
{topic}_6_1.mdxor{topic}-6_1.mdx - NextGen Files:
{topic}.mdxor{topic}_ng.mdx - NextGen Overview:
overview_ng.mdx(notabout_*_ng.mdx) - Canonical URL:
/{version}/{module}/{section}/{page} - Image Paths: Use
../Resources/Images/...(auto-transformed)
- 6.1:
public/images_6_1/ - 6.1.1:
public/images_6_1_1/ - 5.13:
public/images_5_13/ - NextGen:
public/images_ng/
- v1.1.0 (January 2025): Image path transformation, feedback survey, hero redesign, navigation fixes, error boundary improvements
- v1.0.0 (January 2025): Complete SEO/GEO implementation, breadcrumb fixes, NextGen support
- v0.9.0 (December 2024): Page loading fixes, error handling improvements
- v0.8.0 (December 2024): Multi-version support, Admin module expansion
- v0.7.0 (November 2024): Initial release with basic navigation
Last Updated: January 2025
Live Site: https://gopichand-virima.github.io/FeatureDocsite/
Repository: https://github.com/gopichand-virima/FeatureDocsite