Merge pull request #1844 from 0xProject/fix/docFixes
website: Doc Fixes
This commit is contained in:
@@ -71,17 +71,10 @@ const Coverage: React.StatelessComponent<{}> = () => (
|
||||
<List>
|
||||
<ListItem>
|
||||
Use{' '}
|
||||
<a href="https://github.com/ethereum/go-ethereum" target="_blank">
|
||||
Geth
|
||||
<a href="https://github.com/trufflesuite/ganache-cli" target="_blank">
|
||||
Ganache
|
||||
</a>{' '}
|
||||
as a backing node. We recommend using our{' '}
|
||||
<a href="https://hub.docker.com/r/0xorg/devnet" target="_blank">
|
||||
Devnet Docker container
|
||||
</a>{' '}
|
||||
which sets up a Geth node for testing purposes.{' '}
|
||||
<a href="https://github.com/0xProject/0x-monorepo/issues/1520" target="_blank">
|
||||
Ganache support is a work in progress.
|
||||
</a>
|
||||
as a backing node.
|
||||
</ListItem>
|
||||
<ListItem>
|
||||
Understand and use{' '}
|
||||
|
||||
@@ -68,17 +68,10 @@ const Profiler: React.StatelessComponent<{}> = () => (
|
||||
<List>
|
||||
<ListItem>
|
||||
Use{' '}
|
||||
<a href="https://github.com/ethereum/go-ethereum" target="_blank">
|
||||
Geth
|
||||
<a href="https://github.com/trufflesuite/ganache-cli" target="_blank">
|
||||
Ganache
|
||||
</a>{' '}
|
||||
as a backing node. We recommend using our{' '}
|
||||
<a href="https://hub.docker.com/r/0xorg/devnet" target="_blank">
|
||||
Devnet Docker container
|
||||
</a>{' '}
|
||||
which sets up a Geth node for testing purposes.{' '}
|
||||
<a href="https://github.com/0xProject/0x-monorepo/issues/1520" target="_blank">
|
||||
Ganache support is a work in progress.
|
||||
</a>
|
||||
as a backing node.
|
||||
</ListItem>
|
||||
<ListItem>
|
||||
Understand and use{' '}
|
||||
|
||||
@@ -38,17 +38,10 @@ const Trace: React.StatelessComponent<{}> = () => (
|
||||
<List>
|
||||
<ListItem>
|
||||
Use{' '}
|
||||
<a href="https://github.com/ethereum/go-ethereum" target="_blank">
|
||||
Geth
|
||||
<a href="https://github.com/trufflesuite/ganache-cli" target="_blank">
|
||||
Ganache
|
||||
</a>{' '}
|
||||
as a backing node. We recommend using our{' '}
|
||||
<a href="https://hub.docker.com/r/0xorg/devnet" target="_blank">
|
||||
Devnet Docker container
|
||||
</a>{' '}
|
||||
which sets up a Geth node for testing purposes.{' '}
|
||||
<a href="https://github.com/0xProject/0x-monorepo/issues/1520" target="_blank">
|
||||
Ganache support is a work in progress.
|
||||
</a>
|
||||
as a backing node.
|
||||
</ListItem>
|
||||
<ListItem>
|
||||
Understand and use{' '}
|
||||
|
||||
@@ -56,22 +56,6 @@ yarn clean
|
||||
yarn lint
|
||||
```
|
||||
|
||||
### Test providers
|
||||
|
||||
By default tests run against an in-process Ganache instance. If you want to use Geth you'll need to [start a Geth dev node](https://github.com/0xProject/0x-monorepo/blob/v2-prototype/packages/devnet/README.md) first.
|
||||
|
||||
```bash
|
||||
cd ../devnet
|
||||
docker build -t 0x-devnet .
|
||||
docker run -it --rm -p 8501:8501 0x-devnet
|
||||
```
|
||||
|
||||
This Geth version supports snapshots and time travel. Then - run your tests against it.
|
||||
|
||||
```
|
||||
TEST_PROVIDER=geth yarn test
|
||||
```
|
||||
|
||||
### Coverage
|
||||
|
||||
```bash
|
||||
|
||||
@@ -70,4 +70,4 @@ istanbul report html
|
||||
open coverage/index.html
|
||||
```
|
||||
|
||||
Use [Geth](https://github.com/ethereum/go-ethereum) as a backing node. We recommend using our [Devnet Docker container](https://hub.docker.com/r/0xorg/devnet) which sets up a Geth node for testing purposes. Ganache support is a [work in progress](https://github.com/0xProject/0x-monorepo/issues/1520).
|
||||
Use [Ganache](https://github.com/trufflesuite/ganache-cli) as a backing node.
|
||||
|
||||
@@ -71,4 +71,4 @@ istanbul report html
|
||||
open coverage/index.html
|
||||
```
|
||||
|
||||
Use [Geth](https://github.com/ethereum/go-ethereum) as a backing node. We recommend using our [Devnet Docker container](https://hub.docker.com/r/0xorg/devnet) which sets up a Geth node for testing purposes. Ganache support is a [work in progress](https://github.com/0xProject/0x-monorepo/issues/1520).
|
||||
Use [Ganache](https://github.com/trufflesuite/ganache-cli) as a backing node.
|
||||
|
||||
@@ -59,4 +59,4 @@ provider.start();
|
||||
|
||||
Now when you run your tests, it should print out stack traces when encountering an error.
|
||||
|
||||
Use [Geth](https://github.com/ethereum/go-ethereum) as a backing node. We recommend using our [Devnet Docker container](https://hub.docker.com/r/0xorg/devnet) which sets up a Geth node for testing purposes. Ganache support is a [work in progress](https://github.com/0xProject/0x-monorepo/issues/1520).
|
||||
Use [Ganache](https://github.com/trufflesuite/ganache-cli) as a backing node.
|
||||
|
||||
@@ -24,7 +24,7 @@ export const SidebarHeader: React.StatelessComponent<SidebarHeaderProps> = ({
|
||||
return (
|
||||
<Container>
|
||||
<Container className="flex justify-bottom">
|
||||
<Container className="col col-8 pl1">
|
||||
<Container className="col col-7 pl1">
|
||||
<Text
|
||||
fontColor={colors.lightLinkBlue}
|
||||
fontSize={screenWidth === ScreenWidths.Sm ? '20px' : '22px'}
|
||||
@@ -35,7 +35,7 @@ export const SidebarHeader: React.StatelessComponent<SidebarHeaderProps> = ({
|
||||
</Text>
|
||||
</Container>
|
||||
{docsVersion !== undefined && availableDocVersions !== undefined && onVersionSelected !== undefined && (
|
||||
<div className="col col-4 pl1" style={{ alignSelf: 'flex-end', paddingBottom: 4 }}>
|
||||
<div className="col col-5 pl1" style={{ alignSelf: 'flex-end', paddingBottom: 4 }}>
|
||||
<Container className="right">
|
||||
<VersionDropDown
|
||||
selectedVersion={docsVersion}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { colors, constants as sharedConstants, utils as sharedUtils } from '@0x/react-shared';
|
||||
import { colors, constants as sharedConstants } from '@0x/react-shared';
|
||||
import * as _ from 'lodash';
|
||||
import * as React from 'react';
|
||||
import { Helmet } from 'react-helmet';
|
||||
@@ -9,32 +9,13 @@ import { Container } from 'ts/components/ui/container';
|
||||
import { Dispatcher } from 'ts/redux/dispatcher';
|
||||
import { media } from 'ts/style/media';
|
||||
import { styled } from 'ts/style/theme';
|
||||
import { BrowserType, OperatingSystemType, ScreenWidths } from 'ts/types';
|
||||
import { ScreenWidths } from 'ts/types';
|
||||
import { documentConstants } from 'ts/utils/document_meta_constants';
|
||||
import { Translate } from 'ts/utils/translate';
|
||||
import { utils } from 'ts/utils/utils';
|
||||
|
||||
const THROTTLE_TIMEOUT = 100;
|
||||
const TOP_BAR_HEIGHT = 80;
|
||||
const browserType = utils.getBrowserType();
|
||||
let SCROLLBAR_WIDTH;
|
||||
switch (browserType) {
|
||||
case BrowserType.Firefox:
|
||||
// HACK: Firefox doesn't allow styling of their scrollbar's.
|
||||
// Source: https://stackoverflow.com/questions/6165472/custom-css-scrollbar-for-firefox
|
||||
const os = utils.getOperatingSystem();
|
||||
SCROLLBAR_WIDTH = os === OperatingSystemType.Windows ? 17 : 15;
|
||||
break;
|
||||
|
||||
case BrowserType.Edge:
|
||||
// Edge's scrollbar is placed outside of the div content and doesn't
|
||||
// need to be accounted for
|
||||
SCROLLBAR_WIDTH = 0;
|
||||
break;
|
||||
|
||||
default:
|
||||
SCROLLBAR_WIDTH = 4;
|
||||
}
|
||||
const SIDEBAR_PADDING = 22;
|
||||
|
||||
export interface DevelopersPageProps {
|
||||
@@ -50,8 +31,6 @@ export interface DevelopersPageState {
|
||||
isSidebarScrolling: boolean;
|
||||
}
|
||||
|
||||
const isUserOnMobile = sharedUtils.isUserOnMobile();
|
||||
|
||||
const scrollableContainerStyles = `
|
||||
position: absolute;
|
||||
top: ${TOP_BAR_HEIGHT}px;
|
||||
@@ -61,8 +40,6 @@ const scrollableContainerStyles = `
|
||||
overflow-x: hidden;
|
||||
overflow-y: scroll;
|
||||
-webkit-overflow-scrolling: touch;
|
||||
/* Required for hide/show onHover of scrollbar on Microsoft Edge */
|
||||
-ms-overflow-style: -ms-autohiding-scrollbar;
|
||||
`;
|
||||
|
||||
interface SidebarContainerProps {
|
||||
@@ -74,11 +51,6 @@ const SidebarContainer = styled.div<SidebarContainerProps>`
|
||||
padding-top: 27px;
|
||||
padding-left: ${SIDEBAR_PADDING}px;
|
||||
padding-right: ${SIDEBAR_PADDING}px;
|
||||
overflow: hidden;
|
||||
&:hover {
|
||||
overflow: auto;
|
||||
padding-right: ${SIDEBAR_PADDING - SCROLLBAR_WIDTH}px;
|
||||
}
|
||||
`;
|
||||
|
||||
interface MainContentContainerProps {
|
||||
@@ -90,18 +62,9 @@ const MainContentContainer = styled.div<MainContentContainerProps>`
|
||||
padding-top: 0px;
|
||||
padding-left: 50px;
|
||||
padding-right: 50px;
|
||||
overflow: ${isUserOnMobile ? 'auto' : 'hidden'};
|
||||
&:hover {
|
||||
padding-right: ${50 - SCROLLBAR_WIDTH}px;
|
||||
overflow: auto;
|
||||
}
|
||||
${media.small`
|
||||
padding-left: 20px;
|
||||
padding-right: 20px;
|
||||
&:hover {
|
||||
padding-right: ${20 - SCROLLBAR_WIDTH}px;
|
||||
overflow: auto;
|
||||
}
|
||||
`}
|
||||
`;
|
||||
|
||||
|
||||
@@ -64,15 +64,6 @@ const CATEGORY_TO_PACKAGES: ObjectMap<Package[]> = {
|
||||
to: WebsitePaths.ZeroExJs,
|
||||
},
|
||||
},
|
||||
{
|
||||
description:
|
||||
'A Typescript starter project that will walk you through the basics of how to interact with 0x Protocol and trade of an SRA relayer',
|
||||
link: {
|
||||
title: '0x starter project',
|
||||
to: 'https://github.com/0xProject/0x-starter-project',
|
||||
shouldOpenInNewTab: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
description:
|
||||
'Launch a 0x relayer API backend in under a minute with Launch Kit. `0x-launch-kit-backend` is an open-source, free-to-use 0x relayer template that you can use as a starting point for your own project.',
|
||||
@@ -90,6 +81,15 @@ const CATEGORY_TO_PACKAGES: ObjectMap<Package[]> = {
|
||||
to: WebsitePaths.SmartContracts,
|
||||
},
|
||||
},
|
||||
{
|
||||
description:
|
||||
'A Typescript starter project that will walk you through the basics of how to interact with 0x Protocol and trade of an SRA relayer',
|
||||
link: {
|
||||
title: '0x starter project',
|
||||
to: 'https://github.com/0xProject/0x-starter-project',
|
||||
shouldOpenInNewTab: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
description:
|
||||
'An http & websocket client for interacting with relayers that have implemented the [Standard Relayer API](https://github.com/0xProject/standard-relayer-api)',
|
||||
@@ -225,55 +225,6 @@ const CATEGORY_TO_PACKAGES: ObjectMap<Package[]> = {
|
||||
},
|
||||
],
|
||||
[Categories.Ethereum]: [
|
||||
{
|
||||
description:
|
||||
"This package allows you to generate TypeScript contract wrappers from ABI files. It's heavily inspired by Geth abigen but takes a different approach. You can write your custom handlebars templates which will allow you to seamlessly integrate the generated code into your existing codebase with existing conventions.",
|
||||
link: {
|
||||
title: 'abi-gen',
|
||||
to: 'https://github.com/0xProject/0x-monorepo/tree/development/packages/abi-gen',
|
||||
shouldOpenInNewTab: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
description:
|
||||
'A collection of Typescript types that are useful when working on an Ethereum-based project (e.g RawLog, Transaction, TxData, SolidityTypes, etc...).',
|
||||
link: {
|
||||
title: 'ethereum-types',
|
||||
to: WebsitePaths.EthereumTypes,
|
||||
},
|
||||
},
|
||||
{
|
||||
description:
|
||||
'A wrapper around [solc-js](https://github.com/ethereum/solc-js) that adds smart re-compilation, ability to compile an entire project, Solidity version specific compilation, standard input description support and much more.',
|
||||
link: {
|
||||
title: '@0x/sol-compiler',
|
||||
to: WebsitePaths.SolCompiler,
|
||||
},
|
||||
},
|
||||
{
|
||||
description:
|
||||
'A Solidity code coverage tool. Sol-coverage uses transaction traces to figure out which lines of your code has been covered by your tests.',
|
||||
link: {
|
||||
title: '@0x/sol-coverage',
|
||||
to: WebsitePaths.SolCoverage,
|
||||
},
|
||||
},
|
||||
{
|
||||
description:
|
||||
'A Solidity profiler. Sol-profiler uses transaction traces to figure out line-by-line gas consumption.',
|
||||
link: {
|
||||
title: '@0x/sol-profiler',
|
||||
to: WebsitePaths.SolProfiler,
|
||||
},
|
||||
},
|
||||
{
|
||||
description:
|
||||
'A Solidity revert trace tool. Sol-trace prints human-readable revert trace whenever the revert happens.',
|
||||
link: {
|
||||
title: '@0x/sol-trace',
|
||||
to: WebsitePaths.SolTrace,
|
||||
},
|
||||
},
|
||||
{
|
||||
description:
|
||||
'A collection of subproviders to use with [web3-provider-engine](https://www.npmjs.com/package/web3-provider-engine) (e.g subproviders for interfacing with Ledger hardware wallet, Mnemonic wallet, private key wallet, etc...)',
|
||||
@@ -282,73 +233,14 @@ const CATEGORY_TO_PACKAGES: ObjectMap<Package[]> = {
|
||||
to: WebsitePaths.Subproviders,
|
||||
},
|
||||
},
|
||||
{
|
||||
description:
|
||||
'A raw Ethereum JSON RPC client to simplify interfacing with Ethereum nodes. Also includes some convenience functions for awaiting transactions to be mined, converting between token units, etc...',
|
||||
link: {
|
||||
title: '@0x/web3-wrapper',
|
||||
to: WebsitePaths.Web3Wrapper,
|
||||
},
|
||||
},
|
||||
],
|
||||
[Categories.CommunityMaintained]: [
|
||||
{
|
||||
description:
|
||||
'Node.js worker originally built for 0x Tracker which extracts 0x fill events from the Ethereum blockchain and persists them to MongoDB. Support for both V1 and V2 of the 0x protocol is included with events tagged against the protocol version they belong to.',
|
||||
'The Radar Relay SDK is a software development kit that simplifies the interactions with Radar Relay’s APIs',
|
||||
link: {
|
||||
title: '0x Event Extractor',
|
||||
to: 'https://github.com/0xTracker/0x-event-extractor',
|
||||
shouldOpenInNewTab: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
description:
|
||||
'Node.js worker built for 0x Tracker which performs various ETL tasks related to the 0x protocol trading data and other information used on 0x Tracker.',
|
||||
link: {
|
||||
title: '0x Tracker Worker',
|
||||
to: 'https://github.com/0xTracker/0x-tracker-worker',
|
||||
shouldOpenInNewTab: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
description:
|
||||
"ERCdEX's Javascript SDK for trading on their relayer, as well as other Aquaduct partner relayers",
|
||||
link: {
|
||||
title: 'Aquaduct',
|
||||
to: 'https://www.npmjs.com/package/aqueduct',
|
||||
shouldOpenInNewTab: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
description:
|
||||
'SDKs for automation using Aqueduct & ERC dEX. Aqueduct Server is a lightweight, portable and secure server that runs locally on any workstation. The server exposes a small number of foundational endpoints that enable working with the decentralized Aqueduct liquidity pool from any context or programming language.',
|
||||
link: {
|
||||
title: 'Aquaduct Server SDK',
|
||||
to: 'https://github.com/ERCdEX/aqueduct-server-sdk',
|
||||
shouldOpenInNewTab: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
description: "The ERCdEX Trade Widget let's any website provide token liquidity to it's users",
|
||||
link: {
|
||||
to: 'https://github.com/ERCdEX/widget',
|
||||
title: 'ERCdEX Widget',
|
||||
shouldOpenInNewTab: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
description: "ERCdEX's Java SDK for trading on their relayer, as well as other Aquaduct partner relayers",
|
||||
link: {
|
||||
to: 'https://github.com/ERCdEX/java',
|
||||
title: 'ERCdEX Java SDK',
|
||||
shouldOpenInNewTab: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
description: "ERCdEX's Python SDK for trading on their relayer, as well as other Aquaduct partner relayers",
|
||||
link: {
|
||||
to: 'https://github.com/ERCdEX/python',
|
||||
title: 'ERCdEX Python SDK',
|
||||
title: 'Radar SDK',
|
||||
to: 'https://github.com/RadarRelay/sdk',
|
||||
shouldOpenInNewTab: true,
|
||||
},
|
||||
},
|
||||
@@ -378,24 +270,6 @@ const CATEGORY_TO_PACKAGES: ObjectMap<Package[]> = {
|
||||
shouldOpenInNewTab: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
description:
|
||||
'The Radar Relay SDK is a software development kit that simplifies the interactions with Radar Relay’s APIs',
|
||||
link: {
|
||||
title: 'Radar SDK',
|
||||
to: 'https://github.com/RadarRelay/sdk',
|
||||
shouldOpenInNewTab: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
description:
|
||||
'The Ocean provides a simple REST API, WebSockets API, and JavaScript library to help you integrate decentralized trading into your existing trading strategy.',
|
||||
link: {
|
||||
title: 'The Ocean Javascript SDK',
|
||||
to: 'https://github.com/TheOceanTrade/theoceanx-javascript',
|
||||
shouldOpenInNewTab: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
description: "Tokenlon SDK provides APIs for developers to trade of imToken's relayer",
|
||||
link: {
|
||||
@@ -412,6 +286,15 @@ const CATEGORY_TO_PACKAGES: ObjectMap<Package[]> = {
|
||||
shouldOpenInNewTab: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
description:
|
||||
'Node.js worker originally built for 0x Tracker which extracts 0x fill events from the Ethereum blockchain and persists them to MongoDB. Support for both V1 and V2 of the 0x protocol is included with events tagged against the protocol version they belong to.',
|
||||
link: {
|
||||
title: '0x Event Extractor',
|
||||
to: 'https://github.com/0xTracker/0x-event-extractor',
|
||||
shouldOpenInNewTab: true,
|
||||
},
|
||||
},
|
||||
],
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user