@@ -5,31 +5,46 @@ import Layout from '@theme/Layout';
55import { docsRoutes } from '../constants/docsRoutes' ;
66import styles from './examples.module.css' ;
77
8- const evaluationPaths = [
8+ type EvaluationPath = {
9+ eyebrow : string ;
10+ title : string ;
11+ description : string ;
12+ cta : string ;
13+ } & ( { to : string ; href ?: never } | { href : string ; to ?: never } ) ;
14+
15+ const evaluationPaths : EvaluationPath [ ] = [
916 {
1017 eyebrow : 'Evaluator path' ,
1118 title : 'Compare setup approaches' ,
1219 description :
1320 'Start with the docs landing page to choose between new app setup, existing app install, migration, or Pro evaluation.' ,
14- href : docsRoutes . docsGuide ,
21+ to : docsRoutes . docsGuide ,
1522 cta : 'Open the docs guide' ,
1623 } ,
1724 {
1825 eyebrow : 'Migration path' ,
1926 title : 'Move from react-rails' ,
2027 description :
2128 'Follow a migration sequence validated against a real open-source example app instead of reconstructing it from old guides.' ,
22- href : docsRoutes . migrateFromReactRails ,
29+ to : docsRoutes . migrateFromReactRails ,
2330 cta : 'Use the react-rails guide' ,
2431 } ,
2532 {
2633 eyebrow : 'Upgrade path' ,
2734 title : 'Move from OSS to Pro' ,
2835 description :
2936 'If your current app needs more SSR throughput or RSC support, compare OSS and Pro before adding the Pro package.' ,
30- href : docsRoutes . ossVsPro ,
37+ to : docsRoutes . ossVsPro ,
3138 cta : 'Compare OSS and Pro' ,
3239 } ,
40+ {
41+ eyebrow : 'RSC proof path' ,
42+ title : 'Inspect the RSC performance demo' ,
43+ description :
44+ 'Open the LocalHub benchmark dashboard with Lighthouse reports, bundle-size evidence, and SSR/client/RSC comparisons.' ,
45+ href : 'https://rsc.reactonrails.com/search-performance' ,
46+ cta : 'Open RSC benchmark' ,
47+ } ,
3348] ;
3449
3550const exampleApps = [
@@ -51,6 +66,12 @@ const exampleApps = [
5166 'Official Vite Rails sample app used to document migration preflight and dependency lockfile issues.' ,
5267 href : 'https://github.com/ElMassimo/vite_ruby/tree/main/examples/rails' ,
5368 } ,
69+ {
70+ title : 'react-on-rails-demo-marketplace-rsc' ,
71+ description :
72+ 'Public React on Rails Pro + RSC marketplace demo behind the LocalHub Lighthouse and bundle-size comparisons.' ,
73+ href : 'https://github.com/shakacode/react-on-rails-demo-marketplace-rsc' ,
74+ } ,
5475] ;
5576
5677export default function ExamplesPage ( ) : ReactNode {
@@ -79,7 +100,10 @@ export default function ExamplesPage(): ReactNode {
79100 < p className = { styles . cardEyebrow } > { path . eyebrow } </ p >
80101 < h3 > { path . title } </ h3 >
81102 < p > { path . description } </ p >
82- < Link className = { styles . cardLink } to = { path . href } >
103+ < Link
104+ className = { styles . cardLink }
105+ { ...( 'href' in path ? { href : path . href } : { to : path . to } ) }
106+ >
83107 { path . cta }
84108 </ Link >
85109 </ article >
@@ -90,7 +114,7 @@ export default function ExamplesPage(): ReactNode {
90114 < section className = "container" >
91115 < div className = { styles . sectionHeader } >
92116 < p className = { styles . sectionEyebrow } > Reference repos</ p >
93- < h2 > Open-source apps that map to the docs.</ h2 >
117+ < h2 > Public apps and demos that map to the docs.</ h2 >
94118 </ div >
95119 < div className = { styles . grid } >
96120 { exampleApps . map ( ( app ) => (
0 commit comments