Skip to content

Commit 58674b5

Browse files
committed
setLinkComponent(Link)
1 parent 0be9b5b commit 58674b5

File tree

2 files changed

+4
-9
lines changed

2 files changed

+4
-9
lines changed

MyApp.Client/src/main.tsx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,19 +2,21 @@ import './assets/styles/index.css'
22
import './assets/styles/main.css'
33
import 'react/jsx-runtime'
44
import Layout from '@/components/Layout'
5-
import { Loading, ClientContext } from "@servicestack/react"
5+
import { Loading, ClientContext, setLinkComponent } from "@servicestack/react"
66

77
import { ThemeProvider } from "@/components/theme-provider"
88
import { StrictMode, Suspense, useEffect } from 'react'
99
import { createRoot } from 'react-dom/client'
10-
import { BrowserRouter as Router, useRoutes, useLocation } from 'react-router-dom'
10+
import { BrowserRouter as Router, useRoutes, useLocation, Link } from 'react-router-dom'
1111

1212
import routes from '~react-pages'
1313

1414
import press from "virtual:press"
1515
import { PressContext } from './contexts'
1616
import { client, init } from "@/gateway"
1717

18+
// Configure the library to use React Router's Link component
19+
setLinkComponent(Link)
1820
init()
1921

2022
function App() {

NuGet.Config

Lines changed: 0 additions & 7 deletions
This file was deleted.

0 commit comments

Comments
 (0)