This repository has been archived by the owner on May 3, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix link to the logo, add some text in the examples page
- Loading branch information
Showing
2 changed files
with
17 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
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,16 +1,31 @@ | ||
import React from 'react' | ||
import { connect } from 'react-redux' | ||
|
||
import ExampleToggle from '../toggles/ExampleToggle' | ||
import { getConnectedLink } from 'ion-router/Link' | ||
import thing from './Example' | ||
|
||
const Link = getConnectedLink(connect, 'mainStore') | ||
const Example = connect(state => ({ | ||
example: state.examples.example | ||
}), undefined, undefined, { storeKey: 'mainStore' })(thing) | ||
|
||
export default function Examples() { | ||
return ( | ||
<div> | ||
<ExampleToggle component={Example} /> | ||
<ExampleToggle component={Example} else={() => ( | ||
<div> | ||
<h1>Examples of ion-router's power</h1> | ||
<p> | ||
There are many ways ion-router can be used, and this | ||
list will grow as new ones are added. | ||
</p> | ||
<ul> | ||
<li><Link route="examples" example="basic">Basic Example</Link></li> | ||
</ul> | ||
</div> | ||
)} | ||
/> | ||
</div> | ||
) | ||
} |