Skip to content

Commit 81a8afd

Browse files
authored
Merge branch 'master' into chore/throw-on-broken-anchors
2 parents 6885f63 + eb7a498 commit 81a8afd

File tree

201 files changed

+2609
-1195
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

201 files changed

+2609
-1195
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
## Intro
66

7-
This repository is the home of Apify's documentation, which you can find at [docs.apify.com](https://docs.apify.com/). The documentation is written using [Markdown](https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet). Source files of the [platform documentation](https://docs.apify.com/platform) are located in the [/sources](https://github.com/apify/apify-docs/tree/master/sources) directory. However, other sections, such as SDKs for [JavaScript/Node.js](https://docs.apify.com/sdk/js/), [Python](https://docs.apify.com/sdk/python/), or [CLI](https://docs.apify.com/cli), have their own repositories. For more information, see the [Contributing guidelines](./CONTRIBUTING.md).
7+
This repository is the home of Apify's documentation, which you can find at [docs.apify.com](https://docs.apify.com/). The documentation is written using [Markdown](https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet). Source files of the [platform documentation](https://docs.apify.com/platform) are located in the [/sources](https://github.com/apify/apify-docs/tree/master/sources) directory. However, other sections, such as SDKs for [JavaScript/Node.js](https://docs.apify.com/sdk/js/), [Python](https://docs.apify.com/sdk/python/), or [CLI](https://docs.apify.com/cli/), have their own repositories. For more information, see the [Contributing guidelines](./CONTRIBUTING.md).
88

99
## Before you start contributing
1010

_typos.toml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
[default]
22
extend-ignore-re = [
3-
'`[^`\n]+`',
4-
'```[\s\S]*?```',
3+
'`[^`\n]+`', # skip inline code
4+
'```[\s\S]*?```', # skip code blocks
5+
'Bún bò Nam Bô', # otherwise "Nam" is considered as a typo of "Name"
56
]
67

78
[default.extend-words]

apify-docs-theme/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@apify/docs-theme",
3-
"version": "1.0.135",
3+
"version": "1.0.137",
44
"description": "",
55
"main": "./src/index.js",
66
"files": [

apify-docs-theme/src/theme/MDXComponents/Details.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ export default function MDXDetails(props) {
66
// Split summary item from the rest to pass it as a separate prop to the
77
// Details theme component
88
const summary = items.find(
9-
(item) => React.isValidElement(item) && item.props?.mdxType === 'summary',
9+
(item) => React.isValidElement(item) && item.type === 'summary',
1010
);
1111
const children = <>{items.filter((item) => item !== summary)}</>;
1212
return (

apify-docs-theme/src/theme/MDXComponents/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ const MDXComponents = {
1717
code: MDXCode,
1818
a: MDXA,
1919
pre: MDXPre,
20-
details: MDXDetails,
20+
Details: MDXDetails,
2121
ul: MDXUl,
2222
img: MDXImg,
2323
h1: (props) => <MDXHeading as="h1" {...props} />,

apify-docs-theme/src/theme/custom.css

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1549,6 +1549,7 @@ html[data-theme='dark'] .runnable-code-block svg .apify-logo {
15491549
.prism-code.language-javascript .token-line::before,
15501550
.prism-code.language-json .token-line::before,
15511551
.prism-code.language-json5 .token-line::before,
1552+
.prism-code.language-py .token-line::before,
15521553
.prism-code.language-python .token-line::before,
15531554
.prism-code.language-dockerfile .token-line::before,
15541555
.prism-code.language-XML .token-line::before,

clientModule.js

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
// client module for callbacks on route change
2+
// see https://docusaurus.io/docs/advanced/client#client-module-lifecycles
3+
export function onRouteDidUpdate({ location, previousLocation }) {
4+
// Don't execute if we are still on the same page; the lifecycle may be fired
5+
// because the hash changes (e.g. when navigating between headings)
6+
if (location.pathname !== previousLocation?.pathname) {
7+
// hubspot tracking page view
8+
// eslint-disable-next-line no-underscore-dangle, no-multi-assign
9+
const _hsq = window._hsq = window._hsq || [];
10+
_hsq.push(['setPath', window.location.pathname]);
11+
_hsq.push(['trackPageView']);
12+
}
13+
}

docusaurus.config.js

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -195,12 +195,12 @@ module.exports = {
195195
mermaid: true,
196196
parseFrontMatter: async (params) => {
197197
const result = await params.defaultParseFrontMatter(params);
198-
199-
const ogImageURL = new URL('https://apify.com/og-image/docs-article');
200-
201-
ogImageURL.searchParams.set('title', result.frontMatter.title);
202-
result.frontMatter.image ??= ogImageURL.toString();
203-
198+
const isPartial = params.filePath.split('/').pop()[0] === '_';
199+
if (!isPartial) {
200+
const ogImageURL = new URL('https://apify.com/og-image/docs-article');
201+
ogImageURL.searchParams.set('title', result.frontMatter.title);
202+
result.frontMatter.image ??= ogImageURL.toString();
203+
}
204204
return result;
205205
},
206206
},
@@ -212,4 +212,5 @@ module.exports = {
212212
'^/legal/*',
213213
],
214214
},
215+
clientModules: ['./clientModule.js'],
215216
};

0 commit comments

Comments
 (0)