mirror of
https://github.com/oceanprotocol/docs.git
synced 2024-11-26 19:49:26 +01:00
package updates
This commit is contained in:
parent
62d8aac5e2
commit
9503229ae0
@ -13,7 +13,6 @@ It's based on the [TokenBridge by POA Network](https://medium.com/poa-network/in
|
|||||||
|
|
||||||
## Using the Token Bridge
|
## Using the Token Bridge
|
||||||
|
|
||||||
|
|
||||||
### Ethereum Mainnet → Ocean Pacific
|
### Ethereum Mainnet → Ocean Pacific
|
||||||
|
|
||||||
If you want to transfer OCEAN out of the Ethereum Mainnet, then first you need an Ethereum account with some OCEAN in the Ethereum Mainnet, and be connected to Ethereum Mainnet in MetaMask. If you want to get some OCEAN in the Ethereum Mainnet, then see the page about [Ocean Tokens](/concepts/ocean-tokens/).
|
If you want to transfer OCEAN out of the Ethereum Mainnet, then first you need an Ethereum account with some OCEAN in the Ethereum Mainnet, and be connected to Ethereum Mainnet in MetaMask. If you want to get some OCEAN in the Ethereum Mainnet, then see the page about [Ocean Tokens](/concepts/ocean-tokens/).
|
||||||
|
@ -114,7 +114,7 @@ exports.createPages = ({ graphql, actions }) => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
`
|
`
|
||||||
).then(async result => {
|
).then(async (result) => {
|
||||||
if (result.errors) {
|
if (result.errors) {
|
||||||
console.log(result.errors)
|
console.log(result.errors)
|
||||||
reject(result.errors)
|
reject(result.errors)
|
||||||
@ -126,7 +126,7 @@ exports.createPages = ({ graphql, actions }) => {
|
|||||||
//
|
//
|
||||||
// Create Doc pages
|
// Create Doc pages
|
||||||
//
|
//
|
||||||
posts.forEach(post => {
|
posts.forEach((post) => {
|
||||||
createPage({
|
createPage({
|
||||||
path: `${post.node.fields.slug}`,
|
path: `${post.node.fields.slug}`,
|
||||||
component: docTemplate,
|
component: docTemplate,
|
||||||
@ -145,14 +145,14 @@ exports.createPages = ({ graphql, actions }) => {
|
|||||||
postsDevOcean
|
postsDevOcean
|
||||||
// only grab files with required frontmatter defined
|
// only grab files with required frontmatter defined
|
||||||
.filter(
|
.filter(
|
||||||
post =>
|
(post) =>
|
||||||
post.node.frontmatter &&
|
post.node.frontmatter &&
|
||||||
post.node.frontmatter.slug &&
|
post.node.frontmatter.slug &&
|
||||||
post.node.frontmatter.title &&
|
post.node.frontmatter.title &&
|
||||||
post.node.frontmatter.description &&
|
post.node.frontmatter.description &&
|
||||||
post.node.frontmatter.section
|
post.node.frontmatter.section
|
||||||
)
|
)
|
||||||
.forEach(post => {
|
.forEach((post) => {
|
||||||
createPage({
|
createPage({
|
||||||
path: `${post.node.fields.slug}`,
|
path: `${post.node.fields.slug}`,
|
||||||
component: docTemplate,
|
component: docTemplate,
|
||||||
@ -255,7 +255,7 @@ const createTypeDocPage = async (createPage, name, downloadUrl) => {
|
|||||||
// Create pages from swagger json files
|
// Create pages from swagger json files
|
||||||
//
|
//
|
||||||
// https://github.com/swagger-api/swagger-js
|
// https://github.com/swagger-api/swagger-js
|
||||||
const fetchSwaggerSpec = async name => {
|
const fetchSwaggerSpec = async (name) => {
|
||||||
try {
|
try {
|
||||||
const client = await Swagger(
|
const client = await Swagger(
|
||||||
`https://${name}.commons.oceanprotocol.com/spec`
|
`https://${name}.commons.oceanprotocol.com/spec`
|
||||||
@ -275,11 +275,11 @@ const fetchSwaggerSpec = async name => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const createSwaggerPages = async createPage => {
|
const createSwaggerPages = async (createPage) => {
|
||||||
const swaggerComponents = ['aquarius', 'brizo']
|
const swaggerComponents = ['aquarius', 'brizo']
|
||||||
const apiSwaggerTemplate = path.resolve('./src/templates/Swagger/index.jsx')
|
const apiSwaggerTemplate = path.resolve('./src/templates/Swagger/index.jsx')
|
||||||
|
|
||||||
const getSlug = name => {
|
const getSlug = (name) => {
|
||||||
const slug = `/references/${name}/`
|
const slug = `/references/${name}/`
|
||||||
return slug
|
return slug
|
||||||
}
|
}
|
||||||
|
52
package.json
52
package.json
@ -25,38 +25,38 @@
|
|||||||
"@oceanprotocol/art": "^2.2.0",
|
"@oceanprotocol/art": "^2.2.0",
|
||||||
"axios": "^0.19.2",
|
"axios": "^0.19.2",
|
||||||
"classnames": "^2.2.6",
|
"classnames": "^2.2.6",
|
||||||
"gatsby": "^2.19.43",
|
"gatsby": "^2.20.3",
|
||||||
"gatsby-image": "^2.2.43",
|
"gatsby-image": "^2.3.1",
|
||||||
"gatsby-plugin-catch-links": "^2.1.27",
|
"gatsby-plugin-catch-links": "^2.2.1",
|
||||||
"gatsby-plugin-google-analytics": "^2.1.37",
|
"gatsby-plugin-google-analytics": "^2.2.1",
|
||||||
"gatsby-plugin-manifest": "^2.2.47",
|
"gatsby-plugin-manifest": "^2.3.2",
|
||||||
"gatsby-plugin-offline": "^3.0.40",
|
"gatsby-plugin-offline": "^3.1.1",
|
||||||
"gatsby-plugin-react-helmet": "^3.1.23",
|
"gatsby-plugin-react-helmet": "^3.2.1",
|
||||||
"gatsby-plugin-sass": "^2.1.30",
|
"gatsby-plugin-sass": "^2.2.1",
|
||||||
"gatsby-plugin-sharp": "^2.4.12",
|
"gatsby-plugin-sharp": "^2.5.2",
|
||||||
"gatsby-plugin-sitemap": "^2.2.29",
|
"gatsby-plugin-sitemap": "^2.3.1",
|
||||||
"gatsby-plugin-svgr": "^2.0.2",
|
"gatsby-plugin-svgr": "^2.0.2",
|
||||||
"gatsby-plugin-webpack-size": "^1.0.0",
|
"gatsby-plugin-webpack-size": "^1.0.0",
|
||||||
"gatsby-remark-autolink-headers": "^2.1.25",
|
"gatsby-remark-autolink-headers": "^2.2.1",
|
||||||
"gatsby-remark-code-titles": "^1.1.0",
|
"gatsby-remark-code-titles": "^1.1.0",
|
||||||
"gatsby-remark-component": "^1.1.3",
|
"gatsby-remark-component": "^1.1.3",
|
||||||
"gatsby-remark-copy-linked-files": "^2.1.39",
|
"gatsby-remark-copy-linked-files": "^2.2.1",
|
||||||
"gatsby-remark-embed-video": "^2.0.1",
|
"gatsby-remark-embed-video": "^2.0.1",
|
||||||
"gatsby-remark-github": "^2.0.0",
|
"gatsby-remark-github": "^2.0.0",
|
||||||
"gatsby-remark-images": "^3.1.49",
|
"gatsby-remark-images": "^3.2.1",
|
||||||
"gatsby-remark-responsive-iframe": "^2.2.33",
|
"gatsby-remark-responsive-iframe": "^2.3.1",
|
||||||
"gatsby-remark-smartypants": "^2.1.22",
|
"gatsby-remark-smartypants": "^2.2.1",
|
||||||
"gatsby-remark-vscode": "^2.0.3",
|
"gatsby-remark-vscode": "^2.0.3",
|
||||||
"gatsby-source-filesystem": "^2.1.55",
|
"gatsby-source-filesystem": "^2.2.2",
|
||||||
"gatsby-source-graphql": "^2.1.34",
|
"gatsby-source-graphql": "^2.2.1",
|
||||||
"gatsby-transformer-remark": "^2.6.58",
|
"gatsby-transformer-remark": "^2.7.1",
|
||||||
"gatsby-transformer-sharp": "^2.3.18",
|
"gatsby-transformer-sharp": "^2.4.2",
|
||||||
"gatsby-transformer-xml": "^2.1.25",
|
"gatsby-transformer-xml": "^2.2.1",
|
||||||
"gatsby-transformer-yaml": "^2.2.26",
|
"gatsby-transformer-yaml": "^2.3.1",
|
||||||
"giphy-js-sdk-core": "^1.0.6",
|
"giphy-js-sdk-core": "^1.0.6",
|
||||||
"intersection-observer": "^0.7.0",
|
"intersection-observer": "^0.7.0",
|
||||||
"react": "^16.13.0",
|
"react": "^16.13.1",
|
||||||
"react-dom": "^16.13.0",
|
"react-dom": "^16.13.1",
|
||||||
"react-helmet": "^5.2.1",
|
"react-helmet": "^5.2.1",
|
||||||
"react-scrollspy": "^3.4.2",
|
"react-scrollspy": "^3.4.2",
|
||||||
"rehype-react": "^5.0.0",
|
"rehype-react": "^5.0.0",
|
||||||
@ -69,16 +69,16 @@
|
|||||||
"swagger-client": "^3.10.0"
|
"swagger-client": "^3.10.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@svgr/webpack": "^5.2.0",
|
"@svgr/webpack": "^5.3.0",
|
||||||
"dotenv": "^8.2.0",
|
"dotenv": "^8.2.0",
|
||||||
"eslint": "^6.8.0",
|
"eslint": "^6.8.0",
|
||||||
"eslint-config-oceanprotocol": "^1.5.0",
|
"eslint-config-oceanprotocol": "^1.5.0",
|
||||||
"eslint-config-prettier": "^6.10.0",
|
"eslint-config-prettier": "^6.10.1",
|
||||||
"eslint-plugin-prettier": "^3.1.2",
|
"eslint-plugin-prettier": "^3.1.2",
|
||||||
"markdownlint-cli": "^0.22.0",
|
"markdownlint-cli": "^0.22.0",
|
||||||
"node-sass": "^4.13.1",
|
"node-sass": "^4.13.1",
|
||||||
"npm-run-all": "^4.1.5",
|
"npm-run-all": "^4.1.5",
|
||||||
"prettier": "^1.19.1",
|
"prettier": "^2.0.2",
|
||||||
"prettier-stylelint": "^0.4.2",
|
"prettier-stylelint": "^0.4.2",
|
||||||
"stylelint": "^13.2.1",
|
"stylelint": "^13.2.1",
|
||||||
"stylelint-config-bigchaindb": "^1.2.2",
|
"stylelint-config-bigchaindb": "^1.2.2",
|
||||||
|
@ -7,9 +7,7 @@ import styles from './DocHeader.module.scss'
|
|||||||
const DocHeader = ({ title, description, prepend }) => {
|
const DocHeader = ({ title, description, prepend }) => {
|
||||||
const descriptionHtml =
|
const descriptionHtml =
|
||||||
description &&
|
description &&
|
||||||
remark()
|
remark().use(remarkReact).processSync(description).contents
|
||||||
.use(remarkReact)
|
|
||||||
.processSync(description).contents
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<header className={styles.header}>
|
<header className={styles.header}>
|
||||||
|
@ -24,7 +24,7 @@ const query = graphql`
|
|||||||
|
|
||||||
const FooterSocial = ({ social }) => (
|
const FooterSocial = ({ social }) => (
|
||||||
<nav className={styles.links}>
|
<nav className={styles.links}>
|
||||||
{Object.keys(social).map(key => (
|
{Object.keys(social).map((key) => (
|
||||||
<a key={key} href={social[key]}>
|
<a key={key} href={social[key]}>
|
||||||
{key}
|
{key}
|
||||||
</a>
|
</a>
|
||||||
@ -39,7 +39,7 @@ FooterSocial.propTypes = {
|
|||||||
const Footer = () => (
|
const Footer = () => (
|
||||||
<StaticQuery
|
<StaticQuery
|
||||||
query={query}
|
query={query}
|
||||||
render={data => {
|
render={(data) => {
|
||||||
const { siteCompany, social } = data.site.siteMetadata
|
const { siteCompany, social } = data.site.siteMetadata
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
@ -26,7 +26,7 @@ const query = graphql`
|
|||||||
const Header = () => (
|
const Header = () => (
|
||||||
<StaticQuery
|
<StaticQuery
|
||||||
query={query}
|
query={query}
|
||||||
render={data => {
|
render={(data) => {
|
||||||
const { siteTitle } = data.site.siteMetadata
|
const { siteTitle } = data.site.siteMetadata
|
||||||
const sections = data.allSectionsYaml.edges
|
const sections = data.allSectionsYaml.edges
|
||||||
|
|
||||||
|
@ -16,7 +16,7 @@ const HeaderHome = () => (
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
`}
|
`}
|
||||||
render={data => {
|
render={(data) => {
|
||||||
const { siteTitle, siteDescription } = data.site.siteMetadata
|
const { siteTitle, siteDescription } = data.site.siteMetadata
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
@ -18,7 +18,7 @@ const QuickRun = () => (
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
`}
|
`}
|
||||||
render={data => (
|
render={(data) => (
|
||||||
<aside className={styles.quickrun}>
|
<aside className={styles.quickrun}>
|
||||||
<header className={styles.header}>
|
<header className={styles.header}>
|
||||||
<h1 className={styles.tldr}>TL;DR</h1>
|
<h1 className={styles.tldr}>TL;DR</h1>
|
||||||
|
@ -10,7 +10,7 @@ const RepositoryList = ({ repositories }) => (
|
|||||||
<h3 className={styles.repositoryCategoryTitle}>{node.group}</h3>
|
<h3 className={styles.repositoryCategoryTitle}>{node.group}</h3>
|
||||||
|
|
||||||
<div className={styles.repositoryList}>
|
<div className={styles.repositoryList}>
|
||||||
{node.items.map(item => (
|
{node.items.map((item) => (
|
||||||
<Repository
|
<Repository
|
||||||
key={item.name}
|
key={item.name}
|
||||||
name={item.name}
|
name={item.name}
|
||||||
|
@ -26,7 +26,7 @@ const query = graphql`
|
|||||||
const Repositories = () => (
|
const Repositories = () => (
|
||||||
<StaticQuery
|
<StaticQuery
|
||||||
query={query}
|
query={query}
|
||||||
render={data => {
|
render={(data) => {
|
||||||
const repositories = data.allRepositoriesYaml.edges
|
const repositories = data.allRepositoriesYaml.edges
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
@ -9,7 +9,7 @@ export default function Links({ links, url }) {
|
|||||||
<a href={url}>GitHub</a>
|
<a href={url}>GitHub</a>
|
||||||
</li>
|
</li>
|
||||||
{links &&
|
{links &&
|
||||||
links.map(link => (
|
links.map((link) => (
|
||||||
<li key={link.url}>
|
<li key={link.url}>
|
||||||
<a href={link.url}>{link.name}</a>
|
<a href={link.url}>{link.name}</a>
|
||||||
</li>
|
</li>
|
||||||
|
@ -42,12 +42,12 @@ export default class Numbers extends PureComponent {
|
|||||||
})
|
})
|
||||||
|
|
||||||
const repo = response.data
|
const repo = response.data
|
||||||
.map(item => {
|
.map((item) => {
|
||||||
if (item.name === this.props.name) {
|
if (item.name === this.props.name) {
|
||||||
return item
|
return item
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.filter(n => n)
|
.filter((n) => n)
|
||||||
|
|
||||||
const { forks, stars } = repo
|
const { forks, stars } = repo
|
||||||
|
|
||||||
|
@ -6,10 +6,7 @@ import styles from './Readme.module.scss'
|
|||||||
|
|
||||||
export default function Readme({ object }) {
|
export default function Readme({ object }) {
|
||||||
const readmeHtml =
|
const readmeHtml =
|
||||||
object &&
|
object && remark().use(remarkReact).processSync(object.text).contents
|
||||||
remark()
|
|
||||||
.use(remarkReact)
|
|
||||||
.processSync(object.text).contents
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
object && (
|
object && (
|
||||||
|
@ -68,7 +68,7 @@ const queryGithub = graphql`
|
|||||||
const Repository = ({ name, links, readme }) => (
|
const Repository = ({ name, links, readme }) => (
|
||||||
<StaticQuery
|
<StaticQuery
|
||||||
query={queryGithub}
|
query={queryGithub}
|
||||||
render={data => {
|
render={(data) => {
|
||||||
const repositoriesGitHub =
|
const repositoriesGitHub =
|
||||||
data.github.organization.repositories.edges
|
data.github.organization.repositories.edges
|
||||||
const repositoriesYaml = data.allRepositoriesYaml.edges
|
const repositoriesYaml = data.allRepositoriesYaml.edges
|
||||||
@ -79,7 +79,7 @@ const Repository = ({ name, links, readme }) => (
|
|||||||
.map(({ node }) => {
|
.map(({ node }) => {
|
||||||
if (node.name === name) return node
|
if (node.name === name) return node
|
||||||
})
|
})
|
||||||
.filter(n => n)
|
.filter((n) => n)
|
||||||
|
|
||||||
const repo = repoFilteredArray[0]
|
const repo = repoFilteredArray[0]
|
||||||
|
|
||||||
@ -103,14 +103,14 @@ const Repository = ({ name, links, readme }) => (
|
|||||||
const linksFilteredArray = []
|
const linksFilteredArray = []
|
||||||
|
|
||||||
repositoriesYaml.map(({ node }) => {
|
repositoriesYaml.map(({ node }) => {
|
||||||
node.items.forEach(item => {
|
node.items.forEach((item) => {
|
||||||
if (item.name === name) {
|
if (item.name === name) {
|
||||||
linksFilteredArray.push(item.links)
|
linksFilteredArray.push(item.links)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|
||||||
const moreLinks = links || linksFilteredArray.filter(n => n)[0]
|
const moreLinks = links || linksFilteredArray.filter((n) => n)[0]
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<article className={styles.repository}>
|
<article className={styles.repository}>
|
||||||
|
@ -15,7 +15,7 @@ export default class TocScroll extends React.Component {
|
|||||||
smoothscroll.polyfill()
|
smoothscroll.polyfill()
|
||||||
}
|
}
|
||||||
|
|
||||||
handleClick = e => {
|
handleClick = (e) => {
|
||||||
e.preventDefault()
|
e.preventDefault()
|
||||||
|
|
||||||
let elem = 0
|
let elem = 0
|
||||||
|
@ -127,7 +127,7 @@ MetaTags.propTypes = {
|
|||||||
const Seo = ({ title, description, slug, article, location }) => (
|
const Seo = ({ title, description, slug, article, location }) => (
|
||||||
<StaticQuery
|
<StaticQuery
|
||||||
query={query}
|
query={query}
|
||||||
render={data => {
|
render={(data) => {
|
||||||
const siteMeta = data.site.siteMetadata
|
const siteMeta = data.site.siteMetadata
|
||||||
const shareImage =
|
const shareImage =
|
||||||
data.shareImage.edges[0].node.childImageSharp.original.src
|
data.shareImage.edges[0].node.childImageSharp.original.src
|
||||||
|
@ -130,7 +130,7 @@ export default class Sidebar extends Component {
|
|||||||
<div key={i}>
|
<div key={i}>
|
||||||
{collapsed ? (
|
{collapsed ? (
|
||||||
group.items.some(
|
group.items.some(
|
||||||
item => item.link === location.pathname
|
(item) => item.link === location.pathname
|
||||||
) ? (
|
) ? (
|
||||||
<SidebarGroup
|
<SidebarGroup
|
||||||
i={i}
|
i={i}
|
||||||
|
@ -37,7 +37,7 @@ export default class NotFoundPage extends Component {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
handleClick = e => {
|
handleClick = (e) => {
|
||||||
e.preventDefault()
|
e.preventDefault()
|
||||||
this.getRandomGif()
|
this.getRandomGif()
|
||||||
}
|
}
|
||||||
|
@ -25,7 +25,7 @@ const ParameterExample = ({ properties }) => (
|
|||||||
<code className="language-json">
|
<code className="language-json">
|
||||||
{'{'}
|
{'{'}
|
||||||
{properties &&
|
{properties &&
|
||||||
Object.keys(properties).map(key => (
|
Object.keys(properties).map((key) => (
|
||||||
<div key={key}>
|
<div key={key}>
|
||||||
<span className="token property">{` "${key}"`}</span>
|
<span className="token property">{` "${key}"`}</span>
|
||||||
<span className="token operator">: </span>
|
<span className="token operator">: </span>
|
||||||
@ -57,7 +57,7 @@ const Parameters = ({ parameters }) => (
|
|||||||
<>
|
<>
|
||||||
<h4 className={styles.subHeading}>Parameters</h4>
|
<h4 className={styles.subHeading}>Parameters</h4>
|
||||||
|
|
||||||
{parameters.map(parameter => {
|
{parameters.map((parameter) => {
|
||||||
const { name, type, required, description, schema } = parameter
|
const { name, type, required, description, schema } = parameter
|
||||||
|
|
||||||
return (
|
return (
|
||||||
@ -93,7 +93,7 @@ Parameters.propTypes = {
|
|||||||
const Responses = ({ responses }) => (
|
const Responses = ({ responses }) => (
|
||||||
<>
|
<>
|
||||||
<h4 className={styles.subHeading}>Responses</h4>
|
<h4 className={styles.subHeading}>Responses</h4>
|
||||||
{Object.keys(responses).map(key => (
|
{Object.keys(responses).map((key) => (
|
||||||
<div key={key} className={styles.response}>
|
<div key={key} className={styles.response}>
|
||||||
<code>{key}</code> {responses[key].description}
|
<code>{key}</code> {responses[key].description}
|
||||||
</div>
|
</div>
|
||||||
|
@ -9,7 +9,7 @@ import stylesSidebar from '../../components/Sidebar.module.scss'
|
|||||||
const Toc = ({ data }) => {
|
const Toc = ({ data }) => {
|
||||||
const Ids = []
|
const Ids = []
|
||||||
|
|
||||||
const items = Object.keys(data.paths).map(key => {
|
const items = Object.keys(data.paths).map((key) => {
|
||||||
Ids.push(slugify(cleanPathKey(key)))
|
Ids.push(slugify(cleanPathKey(key)))
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
export const cleanPathKey = key => {
|
export const cleanPathKey = (key) => {
|
||||||
let keyCleaned = key
|
let keyCleaned = key
|
||||||
|
|
||||||
if (key.includes('aquarius')) {
|
if (key.includes('aquarius')) {
|
||||||
|
@ -80,7 +80,7 @@ const MethodDetails = ({ property }) => {
|
|||||||
<div>
|
<div>
|
||||||
<h4 className={styles.subHeading}>Parameters</h4>
|
<h4 className={styles.subHeading}>Parameters</h4>
|
||||||
|
|
||||||
{parameters.map(parameter => {
|
{parameters.map((parameter) => {
|
||||||
const { name, type, flags, comment } = parameter
|
const { name, type, flags, comment } = parameter
|
||||||
const { isOptional } = flags
|
const { isOptional } = flags
|
||||||
const description =
|
const description =
|
||||||
@ -242,7 +242,7 @@ const Entities = ({ entities, sourceUrl }) =>
|
|||||||
{children &&
|
{children &&
|
||||||
children
|
children
|
||||||
.filter(filterByKindOfProperty)
|
.filter(filterByKindOfProperty)
|
||||||
.map(property => (
|
.map((property) => (
|
||||||
<PropertyWrapper
|
<PropertyWrapper
|
||||||
key={shortid.generate()}
|
key={shortid.generate()}
|
||||||
property={property}
|
property={property}
|
||||||
|
@ -2,7 +2,7 @@ export const cleanTypedocData = (data, useClasses) => {
|
|||||||
const nodes = data.children
|
const nodes = data.children
|
||||||
|
|
||||||
const cleanData = nodes
|
const cleanData = nodes
|
||||||
.map(node => {
|
.map((node) => {
|
||||||
const child =
|
const child =
|
||||||
node.children &&
|
node.children &&
|
||||||
node.children.filter(
|
node.children.filter(
|
||||||
@ -18,7 +18,7 @@ export const cleanTypedocData = (data, useClasses) => {
|
|||||||
.filter(({ name }) => (useClasses || []).includes(name))
|
.filter(({ name }) => (useClasses || []).includes(name))
|
||||||
.sort((a, b) => useClasses.indexOf(a.name) - useClasses.indexOf(b.name))
|
.sort((a, b) => useClasses.indexOf(a.name) - useClasses.indexOf(b.name))
|
||||||
.map(({ child }) => child)
|
.map(({ child }) => child)
|
||||||
.map(node => ({
|
.map((node) => ({
|
||||||
...node,
|
...node,
|
||||||
children:
|
children:
|
||||||
node &&
|
node &&
|
||||||
|
Loading…
x
Reference in New Issue
Block a user