aboutsummaryrefslogtreecommitdiffstats
path: root/packages/website/ts/index.tsx
diff options
context:
space:
mode:
authorBrandon Millman <brandon.millman@gmail.com>2018-07-27 17:59:35 +0800
committerBrandon Millman <brandon.millman@gmail.com>2018-07-30 15:48:39 +0800
commit5283dcce2ea5878ac45b9b297c0882f926feb344 (patch)
tree719cfb9417d2508822d346c288ef69567d6178f1 /packages/website/ts/index.tsx
parent48e538f5c7dc208775ec71635e4d4866b5907228 (diff)
downloaddexon-0x-contracts-5283dcce2ea5878ac45b9b297c0882f926feb344.tar.gz
dexon-0x-contracts-5283dcce2ea5878ac45b9b297c0882f926feb344.tar.zst
dexon-0x-contracts-5283dcce2ea5878ac45b9b297c0882f926feb344.zip
Create MetaTags component
Diffstat (limited to 'packages/website/ts/index.tsx')
-rw-r--r--packages/website/ts/index.tsx145
1 files changed, 79 insertions, 66 deletions
diff --git a/packages/website/ts/index.tsx b/packages/website/ts/index.tsx
index ed52e28d2..c6d10452f 100644
--- a/packages/website/ts/index.tsx
+++ b/packages/website/ts/index.tsx
@@ -4,6 +4,7 @@ import { render } from 'react-dom';
import { Provider } from 'react-redux';
import { BrowserRouter as Router, Redirect, Route, Switch } from 'react-router-dom';
import * as injectTapEventPlugin from 'react-tap-event-plugin';
+import { MetaTags } from 'ts/components/meta_tags';
import { About } from 'ts/containers/about';
import { FAQ } from 'ts/containers/faq';
import { Jobs } from 'ts/containers/jobs';
@@ -65,73 +66,85 @@ const LazyEthereumTypesDocumentation = createLazyComponent('Documentation', asyn
System.import<any>(/* webpackChunkName: "ethereumTypesDocs" */ 'ts/containers/ethereum_types_documentation'),
);
+const DOCUMENT_TITLE = '0x: The Protocol for Trading Tokens';
+const DOCUMENT_DESCRIPTION = 'An Open Protocol For Decentralized Exchange On The Ethereum Blockchain';
+
render(
- <Router>
- <div>
- <MuiThemeProvider muiTheme={muiTheme}>
- <Provider store={store}>
- <div>
- <Switch>
- <Route exact={true} path="/" component={Landing as any} />
- <Redirect from="/otc" to={`${WebsitePaths.Portal}`} />
- <Route path={WebsitePaths.Careers} component={Jobs as any} />
- <Route path={WebsitePaths.Portal} component={LazyPortal} />
- <Route path={WebsitePaths.FAQ} component={FAQ as any} />
- <Route path={WebsitePaths.About} component={About as any} />
- <Route path={WebsitePaths.Wiki} component={Wiki as any} />
- <Route path={`${WebsitePaths.ZeroExJs}/:version?`} component={LazyZeroExJSDocumentation} />
- <Route path={`${WebsitePaths.Connect}/:version?`} component={LazyConnectDocumentation} />
- <Route
- path={`${WebsitePaths.SolCompiler}/:version?`}
- component={LazySolCompilerDocumentation}
- />
- <Route path={`${WebsitePaths.SolCov}/:version?`} component={LazySolCovDocumentation} />
- <Route
- path={`${WebsitePaths.JSONSchemas}/:version?`}
- component={LazyJSONSchemasDocumentation}
- />
- <Route
- path={`${WebsitePaths.Subproviders}/:version?`}
- component={LazySubprovidersDocumentation}
- />
- <Route
- path={`${WebsitePaths.OrderUtils}/:version?`}
- component={LazyOrderUtilsDocumentation}
- />
- <Route
- path={`${WebsitePaths.Web3Wrapper}/:version?`}
- component={LazyWeb3WrapperDocumentation}
- />
- <Route
- path={`${WebsitePaths.SmartContracts}/:version?`}
- component={LazySmartContractsDocumentation}
- />
- <Route
- path={`${WebsitePaths.EthereumTypes}/:version?`}
- component={LazyEthereumTypesDocumentation}
- />
+ <div>
+ <MetaTags title={DOCUMENT_TITLE} description={DOCUMENT_DESCRIPTION} />
+ <Router>
+ <div>
+ <MuiThemeProvider muiTheme={muiTheme}>
+ <Provider store={store}>
+ <div>
+ <Switch>
+ <Route exact={true} path="/" component={Landing as any} />
+ <Redirect from="/otc" to={`${WebsitePaths.Portal}`} />
+ <Route path={WebsitePaths.Careers} component={Jobs as any} />
+ <Route path={WebsitePaths.Portal} component={LazyPortal} />
+ <Route path={WebsitePaths.FAQ} component={FAQ as any} />
+ <Route path={WebsitePaths.About} component={About as any} />
+ <Route path={WebsitePaths.Wiki} component={Wiki as any} />
+ <Route
+ path={`${WebsitePaths.ZeroExJs}/:version?`}
+ component={LazyZeroExJSDocumentation}
+ />
+ <Route
+ path={`${WebsitePaths.Connect}/:version?`}
+ component={LazyConnectDocumentation}
+ />
+ <Route
+ path={`${WebsitePaths.SolCompiler}/:version?`}
+ component={LazySolCompilerDocumentation}
+ />
+ <Route path={`${WebsitePaths.SolCov}/:version?`} component={LazySolCovDocumentation} />
+ <Route
+ path={`${WebsitePaths.JSONSchemas}/:version?`}
+ component={LazyJSONSchemasDocumentation}
+ />
+ <Route
+ path={`${WebsitePaths.Subproviders}/:version?`}
+ component={LazySubprovidersDocumentation}
+ />
+ <Route
+ path={`${WebsitePaths.OrderUtils}/:version?`}
+ component={LazyOrderUtilsDocumentation}
+ />
+ <Route
+ path={`${WebsitePaths.Web3Wrapper}/:version?`}
+ component={LazyWeb3WrapperDocumentation}
+ />
+ <Route
+ path={`${WebsitePaths.SmartContracts}/:version?`}
+ component={LazySmartContractsDocumentation}
+ />
+ <Route
+ path={`${WebsitePaths.EthereumTypes}/:version?`}
+ component={LazyEthereumTypesDocumentation}
+ />
- {/* Legacy endpoints */}
- <Route
- path={`${WebsiteLegacyPaths.ZeroExJs}/:version?`}
- component={LazyZeroExJSDocumentation}
- />
- <Route
- path={`${WebsiteLegacyPaths.Web3Wrapper}/:version?`}
- component={LazyWeb3WrapperDocumentation}
- />
- <Route
- path={`${WebsiteLegacyPaths.Deployer}/:version?`}
- component={LazySolCompilerDocumentation}
- />
- <Route path={WebsiteLegacyPaths.Jobs} component={Jobs as any} />
- <Route path={`${WebsitePaths.Docs}`} component={LazyZeroExJSDocumentation} />
- <Route component={NotFound as any} />
- </Switch>
- </div>
- </Provider>
- </MuiThemeProvider>
- </div>
- </Router>,
+ {/* Legacy endpoints */}
+ <Route
+ path={`${WebsiteLegacyPaths.ZeroExJs}/:version?`}
+ component={LazyZeroExJSDocumentation}
+ />
+ <Route
+ path={`${WebsiteLegacyPaths.Web3Wrapper}/:version?`}
+ component={LazyWeb3WrapperDocumentation}
+ />
+ <Route
+ path={`${WebsiteLegacyPaths.Deployer}/:version?`}
+ component={LazySolCompilerDocumentation}
+ />
+ <Route path={WebsiteLegacyPaths.Jobs} component={Jobs as any} />
+ <Route path={`${WebsitePaths.Docs}`} component={LazyZeroExJSDocumentation} />
+ <Route component={NotFound as any} />
+ </Switch>
+ </div>
+ </Provider>
+ </MuiThemeProvider>
+ </div>
+ </Router>
+ </div>,
document.getElementById('app'),
);