forked from vercel/next.js
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Replace deprecated
props.url
in examples (vercel#4953)
Following vercel#4952 I found two examples with the deprecated`props.url` : - `with-ioc` - `with-next-routes`
- Loading branch information
1 parent
cf5dd4a
commit b9081a5
Showing
2 changed files
with
6 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
export default props => <h1>About foo {props.url.query.foo} – no `Link` ({typeof props.Link}) available here</h1> | ||
export default props => <h1>About foo – no `Link` ({typeof props.Link}) available here</h1> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,5 @@ | ||
export default props => <h1>About foo {props.url.query.foo}</h1> | ||
import { withRouter } from 'next/router' | ||
|
||
const About = ({router}) => <h1>About foo {router.query.foo}</h1> | ||
|
||
export default withRouter(About) |