blitz-js / legacy-framework

MIT License
3 stars 2 forks source link

Base path reports error #52

Closed Duckinm closed 3 years ago

Duckinm commented 3 years ago

What is the problem?

Whenever you set your own custom basepath in blitz.config.ts or blitz.config.js

All of the pages using Link components by Blitz will get warn: import { Link } from 'blitz'

Paste all your error logs here:

From Chrome dev tools
Warning: Prop `href` did not match. Server: "/dashboard" Client: "/admin/dashboard"

From Terminal
warn  - Duplicate page detected. pages/app/admin/pages/dashboard.tsx and pages/app/pages/dashboard.tsx both resolve to /dashboard.

What are detailed steps to reproduce this?

Have to fix something on { Link } from 'blitz' to make it work properly, but you can make the warning disappear by using import Link from 'next/link' instead

Screen Shot 2564-07-29 at 12 52 20 AM