Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Formatted with prettier #2972

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion .prettierrc.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"singleQuote": true,
"tabWidth": 4,
"printWidth": 150,
"printWidth": 120,
"semi": false,
"trailingComma": "none",
"overrides": [
Expand Down
325 changes: 159 additions & 166 deletions docs/docusaurus.config.ts
Original file line number Diff line number Diff line change
@@ -1,180 +1,173 @@
import { themes as prismThemes } from 'prism-react-renderer';
import type { Config } from '@docusaurus/types';
import type * as Preset from '@docusaurus/preset-classic';
const path = require("path")
import { themes as prismThemes } from 'prism-react-renderer'
import type { Config } from '@docusaurus/types'
import type * as Preset from '@docusaurus/preset-classic'
const path = require('path')

// This runs in Node.js - Don't use client-side code here (browser APIs, JSX...)

const config: Config = {
title: 'Streamr Docs',
tagline: 'Publish and subscribe to real-time data powered by the decentralized Streamr network."',
favicon: 'img/streamr-logo.svg',

// Set the production url of your site here
url: 'https://docs.streamr.network/',
// Set the /<baseUrl>/ pathname under which your site is served
// For GitHub pages deployment, it is often '/<projectName>/'
baseUrl: '/',


// GitHub pages deployment config.
// If you aren't using GitHub pages, you don't need these.
organizationName: 'streamr-dev', // Usually your GitHub org/user name.
projectName: 'documentation', // Usually your repo name.

onBrokenLinks: 'throw',
onBrokenMarkdownLinks: 'throw',

// Even if you don't use internationalization, you can use this field to set
// useful metadata like html lang. For example, if your site is Chinese, you
// may want to replace "en" with "zh-Hans".
i18n: {
defaultLocale: 'en',
locales: ['en'],
},
plugins: [
[
"docusaurus-plugin-typedoc",

// Plugin / TypeDoc options
{
entryPoints: ["../packages/sdk/src/exports.ts"],
disableSources: true,
name: "API reference",
excludePrivate: true,
excludeProtected: true,
excludeInternal: true,
excludeExternals: true,
includeVersion: true,
categorizeByGroup: true,
treatWarningsAsErrors: true,
watch: process.env.TYPEDOC_WATCH,
sidebar: {
categoryLabel: "API reference",
indexLabel: "API reference",
position: 5,
},
out: "docs/usage/sdk/api",
tsconfig: "../packages/sdk/tsconfig.json",
entryFileName: "api.md",
membersWithOwnFile: ["Class", "Enum", "Interface"],
mergeReadme: false,
readme: "none"
},

]
],
title: 'Streamr Docs',
tagline: 'Publish and subscribe to real-time data powered by the decentralized Streamr network."',
favicon: 'img/streamr-logo.svg',

// Set the production url of your site here
url: 'https://docs.streamr.network/',
// Set the /<baseUrl>/ pathname under which your site is served
// For GitHub pages deployment, it is often '/<projectName>/'
baseUrl: '/',

// GitHub pages deployment config.
// If you aren't using GitHub pages, you don't need these.
organizationName: 'streamr-dev', // Usually your GitHub org/user name.
projectName: 'documentation', // Usually your repo name.

onBrokenLinks: 'throw',
onBrokenMarkdownLinks: 'throw',

// Even if you don't use internationalization, you can use this field to set
// useful metadata like html lang. For example, if your site is Chinese, you
// may want to replace "en" with "zh-Hans".
i18n: {
defaultLocale: 'en',
locales: ['en']
},
plugins: [
[
'docusaurus-plugin-typedoc',

presets: [
[
'classic',
{
googleTagManager: {
containerId: 'GTM-W9HTMKM',
},
docs: {
routeBasePath: "/",
sidebarPath: './sidebars.ts',
editUrl:
'https://github.com/streamr-dev/network/tree/main/docs',
},
blog: {
showReadingTime: true,
editUrl:
'https://blog.streamr.network/',
},
theme: {
customCss: './src/css/custom.css',
},
} satisfies Preset.Options,
// Plugin / TypeDoc options
{
entryPoints: ['../packages/sdk/src/exports.ts'],
disableSources: true,
name: 'API reference',
excludePrivate: true,
excludeProtected: true,
excludeInternal: true,
excludeExternals: true,
includeVersion: true,
categorizeByGroup: true,
treatWarningsAsErrors: true,
watch: process.env.TYPEDOC_WATCH,
sidebar: {
categoryLabel: 'API reference',
indexLabel: 'API reference',
position: 5
},
out: 'docs/usage/sdk/api',
tsconfig: '../packages/sdk/tsconfig.json',
entryFileName: 'api.md',
membersWithOwnFile: ['Class', 'Enum', 'Interface'],
mergeReadme: false,
readme: 'none'
}
]
],
],

themeConfig: {
metadata: [
{ name: "robots", content: "index, follow" }
presets: [
[
'classic',
{
googleTagManager: {
containerId: 'GTM-W9HTMKM'
},
docs: {
routeBasePath: '/',
sidebarPath: './sidebars.ts',
editUrl: 'https://github.com/streamr-dev/network/tree/main/docs'
},
blog: {
showReadingTime: true,
editUrl: 'https://blog.streamr.network/'
},
theme: {
customCss: './src/css/custom.css'
}
} satisfies Preset.Options
]
],
navbar: {
title: 'Streamr',
logo: {
alt: 'Streamr Logo',
src: 'img/streamr-logo.svg',
}
},
algolia: {
// The application ID provided by Algolia
appId: "NOLYN2Z67B",

// Public API key: it is safe to commit it
apiKey: "f9fcf2cbeb33f2edee5ee580110d8045",
themeConfig: {
metadata: [{ name: 'robots', content: 'index, follow' }],
navbar: {
title: 'Streamr',
logo: {
alt: 'Streamr Logo',
src: 'img/streamr-logo.svg'
}
},
algolia: {
// The application ID provided by Algolia
appId: 'NOLYN2Z67B',

indexName: "streamr",
// Public API key: it is safe to commit it
apiKey: 'f9fcf2cbeb33f2edee5ee580110d8045',

// Optional: see doc section below
contextualSearch: true,
schedule: 'every 1 day at 3:00 pm',
indexName: 'streamr',

},
footer: {
links: [
{
title: "DOCS",
items: [
{
label: "Quickstart guides",
to: "guides/nodejs",
},
{
label: "Usage",
to: "usage/authenticate",
},
{
label: "Streamr Network",
to: "streamr-network",
},
{
label: "Node operators",
to: "streamr-network/network-roles/operators",
},
{
label: "Help",
to: "help/developer-faq",
},
],
// Optional: see doc section below
contextualSearch: true,
schedule: 'every 1 day at 3:00 pm'
},
{
title: "COMMUNITY",
items: [
{
label: "Discord",
href: "https://discord.gg/gZAm8P7hK8",
},
{
label: "Twitter",
href: "https://twitter.com/streamr",
},
],
},
{
title: "MORE",
items: [
{
label: "Blog",
href: "https://blog.streamr.network/",
},
{
label: "GitHub",
href: "https://github.com/streamr-dev",
},
],
footer: {
links: [
{
title: 'DOCS',
items: [
{
label: 'Quickstart guides',
to: 'guides/nodejs'
},
{
label: 'Usage',
to: 'usage/authenticate'
},
{
label: 'Streamr Network',
to: 'streamr-network'
},
{
label: 'Node operators',
to: 'streamr-network/network-roles/operators'
},
{
label: 'Help',
to: 'help/developer-faq'
}
]
},
{
title: 'COMMUNITY',
items: [
{
label: 'Discord',
href: 'https://discord.gg/gZAm8P7hK8'
},
{
label: 'Twitter',
href: 'https://twitter.com/streamr'
}
]
},
{
title: 'MORE',
items: [
{
label: 'Blog',
href: 'https://blog.streamr.network/'
},
{
label: 'GitHub',
href: 'https://github.com/streamr-dev'
}
]
}
]
},
],
},
prism: {
theme: prismThemes.github,
darkTheme: prismThemes.dracula,
},
} satisfies Preset.ThemeConfig,
};

export default config;
prism: {
theme: prismThemes.github,
darkTheme: prismThemes.dracula
}
} satisfies Preset.ThemeConfig
}

export default config
10 changes: 5 additions & 5 deletions docs/sidebars.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import type { SidebarsConfig } from '@docusaurus/plugin-content-docs';
import type { SidebarsConfig } from '@docusaurus/plugin-content-docs'

// This runs in Node.js - Don't use client-side code here (browser APIs, JSX...)
const sidebars: SidebarsConfig = {
// By default, Docusaurus generates a sidebar from the docs folder structure
streamrSidebar: [{ type: 'autogenerated', dirName: '.' }],
};
// By default, Docusaurus generates a sidebar from the docs folder structure
streamrSidebar: [{ type: 'autogenerated', dirName: '.' }]
}

export default sidebars;
export default sidebars
4 changes: 2 additions & 2 deletions docs/src/pages/api-docs.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import Layout from "@theme/Layout"
import React from "react"
import Layout from '@theme/Layout'
import React from 'react'

export default function APIDocs(): JSX.Element {
return <Layout title="API docs" description="Streamr API docs"></Layout>
Expand Down
20 changes: 10 additions & 10 deletions docs/static/assets/default.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"client": {
"auth": {
"privateKey": "NODE_PRIVATE_KEY"
}
},
"plugins": {
"operator": {
"operatorContractAddress": "YOUR_OPERATOR_CONTRACT_ADDRESS"
}
"client": {
"auth": {
"privateKey": "NODE_PRIVATE_KEY"
}
}
},
"plugins": {
"operator": {
"operatorContractAddress": "YOUR_OPERATOR_CONTRACT_ADDRESS"
}
}
}
Loading
Loading