Skip to content

Commit

Permalink
chore(global): updated docs for release
Browse files Browse the repository at this point in the history
  • Loading branch information
tgreyuk committed Apr 30, 2024
1 parent 08e6005 commit 647d03b
Show file tree
Hide file tree
Showing 57 changed files with 1,168 additions and 1,128 deletions.
2 changes: 1 addition & 1 deletion .changeset/changelog.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
const getReleaseLine = async (changeset, _type) => {
return changeset.summary.replace(
/\(\#(.+?)\)/g,
'([#$1](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/$1))',
'([#$1](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/$1))',
);
};

Expand Down
2 changes: 1 addition & 1 deletion .changeset/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"$schema": "https://unpkg.com/@changesets/config@2.3.0/schema.json",
"changelog": [
"./changelog.js",
{ "repo": "tgreyuk/typedoc-plugin-markdown" }
{ "repo": "typedoc2md/typedoc-plugin-markdown" }
],
"commit": false,
"fixed": [],
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
node-version: ${{ matrix.node }}
cache: 'npm'
- name: Install
run: npm install
run: HUSKY=0 npm install
- name: Lint
run: npm run lint --workspace typedoc-plugin-markdown
- name: Build
Expand Down
16 changes: 8 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,21 +6,21 @@ This project is a collection of packages designed for generate TypeScript API do

| Package | Badges |
| :---| :---|
[typedoc-plugin-markdown](./packages/typedoc-plugin-markdown#readme) | ![npm](https://img.shields.io/npm/v/typedoc-plugin-markdown%2Fnext?&logo=npm) ![Downloads](https://img.shields.io/npm/dm/typedoc-plugin-markdown) |
[typedoc-plugin-frontmatter](./packages/typedoc-plugin-frontmatter#readme) | ![npm](https://img.shields.io/npm/v/typedoc-plugin-frontmatter%2Fnext?&logo=npm) ![Downloads](https://img.shields.io/npm/dm/typedoc-plugin-frontmatter) |
[typedoc-plugin-remark](./packages/typedoc-plugin-remark#readme) | ![npm](https://img.shields.io/npm/v/typedoc-plugin-remark%2Fnext?&logo=npm) ![Downloads](https://img.shields.io/npm/dm/typedoc-plugin-remark) |
[typedoc-github-wiki-theme](./packages/typedoc-github-wiki-theme#readme) | ![npm](https://img.shields.io/npm/v/typedoc-github-wiki-theme%2Fnext?&logo=npm) ![Downloads](https://img.shields.io/npm/dm/typedoc-github-wiki-theme) |
[typedoc-gitlab-wiki-theme](./packages/typedoc-gitlab-wiki-theme#readme) | ![npm](https://img.shields.io/npm/v/typedoc-gitlab-wiki-theme%2Fnext?&logo=npm) ![Downloads](https://img.shields.io/npm/dm/typedoc-gitlab-wiki-theme) |
[typedoc-vitepress-theme](./packages/typedoc-vitepress-theme#readme) | ![npm](https://img.shields.io/npm/v/typedoc-vitepress-theme%2Fnext?&logo=npm) ![Downloads](https://img.shields.io/npm/dm/typedoc-vitepress-theme) |
[docusaurus-plugin-typedoc](./packages/docusaurus-plugin-typedoc#readme) | ![npm](https://img.shields.io/npm/v/docusaurus-plugin-typedoc%2Fnext?&logo=npm) ![Downloads](https://img.shields.io/npm/dm/docusaurus-plugin-typedoc) |
[typedoc-plugin-markdown](./packages/typedoc-plugin-markdown#readme) | [![npm](https://img.shields.io/npm/v/typedoc-plugin-markdown.svg?logo=npm)](https://www.npmjs.com/package/typedoc-plugin-markdown) ![Downloads](https://img.shields.io/npm/dm/typedoc-plugin-markdown?label=↓) |
[typedoc-plugin-frontmatter](./packages/typedoc-plugin-frontmatter#readme) | [![npm](https://img.shields.io/npm/v/typedoc-plugin-frontmatter.svg?logo=npm)](https://www.npmjs.com/package/typedoc-plugin-frontmatter) ![Downloads](https://img.shields.io/npm/dm/typedoc-plugin-frontmatter?label=↓) |
[typedoc-plugin-remark](./packages/typedoc-plugin-remark#readme) | [![npm](https://img.shields.io/npm/v/typedoc-plugin-remark.svg?logo=npm)](https://www.npmjs.com/package/typedoc-plugin-remark) ![Downloads](https://img.shields.io/npm/dm/typedoc-plugin-remark?label=↓) |
[typedoc-github-wiki-theme](./packages/typedoc-github-wiki-theme#readme) | [![npm](https://img.shields.io/npm/v/typedoc-github-wiki-theme.svg?logo=npm)](https://www.npmjs.com/package/typedoc-github-wiki-theme) ![Downloads](https://img.shields.io/npm/dm/typedoc-github-wiki-theme?label=↓) |
[typedoc-gitlab-wiki-theme](./packages/typedoc-gitlab-wiki-theme#readme) | [![npm](https://img.shields.io/npm/v/typedoc-gitlab-wiki-theme.svg?logo=npm)](https://www.npmjs.com/package/typedoc-gitlab-wiki-theme) ![Downloads](https://img.shields.io/npm/dm/typedoc-gitlab-wiki-theme?label=↓) |
[typedoc-vitepress-theme](./packages/typedoc-vitepress-theme#readme) | [![npm](https://img.shields.io/npm/v/typedoc-vitepress-theme.svg?logo=npm)](https://www.npmjs.com/package/typedoc-vitepress-theme) ![Downloads](https://img.shields.io/npm/dm/typedoc-vitepress-theme?label=↓) |
[docusaurus-plugin-typedoc](./packages/docusaurus-plugin-typedoc#readme) | [![npm](https://img.shields.io/npm/v/docusaurus-plugin-typedoc.svg?logo=npm)](https://www.npmjs.com/package/docusaurus-plugin-typedoc) ![Downloads](https://img.shields.io/npm/dm/docusaurus-plugin-typedoc?label=↓) |

## Documentation

Please see [typedoc-plugin-markdown.org](https://typedoc-plugin-markdown.org).

## Examples

Please see the [examples repository](https://github.com/tgreyuk/typedoc-plugin-markdown-examples).
Please see the [examples repository](https://github.com/typedoc2md/typedoc-plugin-markdown-examples).

## Contributing

Expand Down
2 changes: 1 addition & 1 deletion devtools/examples/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ These folder is intended for internal dev purposes.

For plugin examples please visit:

- https://github.com/tgreyuk/typedoc-plugin-markdown-examples
- https://github.com/typedoc2md/typedoc-plugin-markdown-examples
- https://github.com/tgreyuk/typedoc-vitepress-theme-example
8 changes: 5 additions & 3 deletions devtools/packages/prebuild-options/tasks/generate-docs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,11 @@ export async function generateOptionsDocs(docsConfig: DocsConfig) {
`<Callout type="info">These options should be used in conjunction with the core [TypeDoc options](/docs/using-typedoc).</Callout>`,
);
} else {
out.push(
`<Callout type="info">Please view options exposed by [typedoc-plugin-markdown](/docs/options) in addition to those listed here.</Callout>`,
);
if (docsConfig.presets) {
out.push(
`<Callout type="info">Please view options exposed by [typedoc-plugin-markdown](/docs/options) in addition to those listed here.</Callout>`,
);
}
}

if (docsConfig.presets) {
Expand Down
22 changes: 11 additions & 11 deletions devtools/scripts/generate-readmes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,7 @@ copyChangelog();

async function copyChangelog() {
const changelog = fs.readFileSync(
path.join(
__dirname,
'../../packages/typedoc-plugin-markdown/CHANGELOG_V4.md',
),
path.join(__dirname, '../../packages/typedoc-plugin-markdown/CHANGELOG.md'),
);
const readmeContents = changelog
.toString()
Expand Down Expand Up @@ -65,8 +62,8 @@ function writeRepositoryReadme(packages: any) {
const table: string[] = [];
const rows = packages.map((packageItem) => {
const badges = [
`![npm](https://img.shields.io/npm/v/${packageItem.name}%2Fnext?\&logo=npm)`,
`![Downloads](https://img.shields.io/npm/dm/${packageItem.name})`,
`[![npm](https://img.shields.io/npm/v/${packageItem.name}.svg?logo=npm)](https://www.npmjs.com/package/${packageItem.name})`,
`![Downloads](https://img.shields.io/npm/dm/${packageItem.name}?label=↓)`,
];
return (
[
Expand All @@ -88,7 +85,7 @@ function writeRepositoryReadme(packages: any) {
readme.push('## Examples');

readme.push(
'Please see the [examples repository](https://github.com/tgreyuk/typedoc-plugin-markdown-examples).',
'Please see the [examples repository](https://github.com/typedoc2md/typedoc-plugin-markdown-examples).',
);

readme.push('## Contributing');
Expand All @@ -111,25 +108,28 @@ function writePackageReadme(packageItem: any) {
: `ci.${packageItem.name}.yml`;
const readme = [`# ${packageItem.name}`];
const badges = [
`![npm](https://img.shields.io/npm/v/${packageItem.name}%2Fnext?\&logo=npm)`,
`[![Build Status](https://github.com/tgreyuk/typedoc-plugin-markdown/actions/workflows/${ciName}/badge.svg?branch=next)](https://github.com/tgreyuk/typedoc-plugin-markdown/actions/workflows/${ciName})`,
`[![npm](https://img.shields.io/npm/v/${packageItem.name}.svg?logo=npm)](https://www.npmjs.com/package/${packageItem.name})`,
`[![Build Status](https://github.com/typedoc2md/typedoc-plugin-markdown/actions/workflows/${ciName}/badge.svg?branch=main&style=flat-square)](https://github.com/typedoc2md/typedoc-plugin-markdown/actions/workflows/${ciName})`,
];

readme.push(badges.join(' '));
readme.push(`${packageItem.description}`);
readme.push(`> ${packageItem.description}`);
const docLink = `https://typedoc-plugin-markdown.org${
DOCS_CONFIG[packageItem.name].docsPath
}`;

readme.push('## Installation');
readme.push(`\`\`\`shell
npm install ${packageItem.name}@next --save-dev
npm install ${packageItem.name} --save-dev
\`\`\``);

readme.push('## Documentation');
const resources = [docText(docLink)];
readme.push(resources.join('\n'));

readme.push('## License');
readme.push('MIT');

fs.writeFileSync(
`./packages/${packageItem.name}/README.md`,
readme.join('\n\n'),
Expand Down
4 changes: 2 additions & 2 deletions docs/pages/api-docs/Class.MarkdownPageEvent.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ An event emitted by before and after the markup of a page is rendered.

```ts
export function load(app: MarkdownApplication) {
app.renderer.on(MarkdownPageEvent.END, (event: MarkdownPageEvent) => {
events.contents = event.contents.replace('foo', 'bar');
app.renderer.on(MarkdownPageEvent.BEGIN, (page: MarkdownPageEvent) => {
page.contents = page.contents.replace('foo', 'bar');
});
});
```
Expand Down
56 changes: 28 additions & 28 deletions docs/pages/docs/changelog.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { Callout } from 'nextra/components';

# Changelog

## 4.0.0-next.xx
## 4.0.0 (2024-05-03)

<Callout> v4 is a major release that includes a number of bug fixes, new features and UI improvements.</Callout>

Expand Down Expand Up @@ -43,32 +43,32 @@ Migrating from v3 to v4 should be fairly straightforward. These pointers will he

The release features numerous bug fixes including:

- Duplication in callback/callable/function properties. ([#581](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/581)).
- @experimental / @internal annotations. ([#556](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/556))
- Fix events output and strike-through deprecated items. ([#534](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/534))
- Class static functions are no longer marked. ([#533](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/533))
- @example block not rendered with Headline ([#501](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/501))
- Support for categories ([#499](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/499))
- Correctly resolve packge readme urls from member pages. ([#483](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/483))
- Add the ability to add a separate frontmatter for readme file. ([#469](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/469))
- Items in tables are not linkable. ([#463](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/463))
- Custom i18n texts. ([#458](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/458))
- How to improve the formatting for types?. ([#456](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/456))
- How to change title format. ([#450](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/450))
- Export Docusaurus plugin options type. ([#440](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/440))
- How to export interface as a table. ([#403](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/403))
- Broken Link caused by Typescript class being defined in an index file. ([#402](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/403))
- Markdown plugin inserts unnecessary escape characters. ([#398](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/398))
- Potential bug with optional function argument. ([#396](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/396))
- Respect monorepo `readmeFile` configuration ([#383](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/383))
- Embed all objects under a Module/Namespace onto single page. ([#338](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/338))
- Extra spaces when merging lines in a table. ([#331](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/331))
- Does not support namespace (or module) and interface with same name. ([#300](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/300))
- Integration with VitePress? ([#287](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/287))
- Typedoc comments with text wrapped in `<` and `>` breaks Docusaurus Markdown parser. ([#276](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/276))
- Navigation support? ([#262](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/262))
- Sidebar Category Support? ([#213](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/213))
- Properties as Table like function properties. ([#109](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/109))
- Provide a link/excerpt/screenshot to a demo/example rendered outpout ([#102](https://github.com/tgreyuk/typedoc-plugin-markdown/issues/102))
- Duplication in callback/callable/function properties. ([#581](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/581)).
- @experimental / @internal annotations. ([#556](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/556))
- Fix events output and strike-through deprecated items. ([#534](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/534))
- Class static functions are no longer marked. ([#533](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/533))
- @example block not rendered with Headline ([#501](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/501))
- Support for categories ([#499](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/499))
- Correctly resolve packge readme urls from member pages. ([#483](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/483))
- Add the ability to add a separate frontmatter for readme file. ([#469](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/469))
- Items in tables are not linkable. ([#463](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/463))
- Custom i18n texts. ([#458](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/458))
- How to improve the formatting for types?. ([#456](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/456))
- How to change title format. ([#450](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/450))
- Export Docusaurus plugin options type. ([#440](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/440))
- How to export interface as a table. ([#403](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/403))
- Broken Link caused by Typescript class being defined in an index file. ([#402](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/403))
- Markdown plugin inserts unnecessary escape characters. ([#398](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/398))
- Potential bug with optional function argument. ([#396](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/396))
- Respect monorepo `readmeFile` configuration ([#383](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/383))
- Embed all objects under a Module/Namespace onto single page. ([#338](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/338))
- Extra spaces when merging lines in a table. ([#331](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/331))
- Does not support namespace (or module) and interface with same name. ([#300](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/300))
- Integration with VitePress? ([#287](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/287))
- Typedoc comments with text wrapped in `<` and `>` breaks Docusaurus Markdown parser. ([#276](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/276))
- Navigation support? ([#262](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/262))
- Sidebar Category Support? ([#213](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/213))
- Properties as Table like function properties. ([#109](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/109))
- Provide a link/excerpt/screenshot to a demo/example rendered outpout ([#102](https://github.com/typedoc2md/typedoc-plugin-markdown/issues/102))


2 changes: 1 addition & 1 deletion docs/pages/docs/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ Since many tools and platforms support Markdown, the documentation generated by
- Works alongside other TypeDoc plugins.
- Configurable output file structure.
- Configurable UX options
- [Frontmatter](/plugins/frontmatter) and [Remark](/plugins/remark) utility plugins available.
- Additonal utility plugins available.

## Examples

Expand Down
2 changes: 1 addition & 1 deletion docs/pages/docs/quick-start.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { Callout, Steps } from 'nextra/components';
## Installation

```sh npm2yarn
npm install typedoc typedoc-plugin-markdown@next --save-dev
npm install typedoc typedoc-plugin-markdown --save-dev
```

## Usage
Expand Down
1 change: 0 additions & 1 deletion docs/pages/plugins/_meta.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ export default {
'github-wiki': 'Github Wiki',
'gitlab-wiki': 'Gitlab Wiki',
vitepress: '',

'-- Integrations': {
type: 'separator',
title: 'Integrations',
Expand Down
13 changes: 12 additions & 1 deletion docs/pages/plugins/docusaurus/_meta.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,16 @@
export default {
'quick-start': '',
options: '',
guide: 'Guide',
'-- Guide': {
type: 'separator',
title: 'Guide',
},
sidebar: '',
'multi-instance': '',
'watch-mode': '',
'-- Support': {
type: 'separator',
title: 'Support',
},
'migration-guide': 'Migrating from 0.x.x',
};
5 changes: 0 additions & 5 deletions docs/pages/plugins/docusaurus/guide/_meta.js

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,23 +1,11 @@
# Changelog
# 🚀 Migrating from 0.x.x

## 1.0.0-next.xx

> v1 is a new release along with typedoc-plugin-markdown v4.
### 🚀 Migrating from 0.x.x

#### 💥 Breaking Changes

##### typedoc-plugin-Markdown

- Please see typedoc-plugin-markdown migration guide for details on how to migrate from v3 to v4.

##### Sidebar
## Sidebar

- A manual sidebar file should be referenced in `sidebars.js` rather than autogenerated configuration as previouslly recommended. See [sidebar guide](/plugins/docusaurus/guide/sidebar).
- With the updated configuration the existing sidebar options `position` and `categoryLabel` are no longer relevant.

##### Other options
## Options

- `includeExtension` has been removed as this behaviour is now the default.
- `frontmatter` option has been removed. Please use `typedoc-plugin-frontmatter`.
4 changes: 2 additions & 2 deletions docs/pages/plugins/docusaurus/quick-start.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { Callout, Steps, FileTree } from 'nextra/components';
Install Docusaurus in the root of your project and install the plugin dependencies in the same location as the Docusaurus website directory.

```sh npm2yarn
npm install typedoc typedoc-plugin-markdown@next docusaurus-plugin-typedoc@next --save-dev
npm install typedoc typedoc-plugin-markdown docusaurus-plugin-typedoc --save-dev
```

## Usage
Expand All @@ -21,7 +21,7 @@ https://docusaurus.io/docs/installation
A typical project structure might look like this but can be customized to your needs:

<FileTree>
<FileTree.Folder name="docusauruss-website" defaultOpen>
<FileTree.Folder name="docusaurus-website" defaultOpen>
<FileTree.Folder name="build (static site dir)"></FileTree.Folder>
<FileTree.Folder name="docs" defaultOpen>
<FileTree.Folder name="api (generated TypeDoc md)"></FileTree.Folder>
Expand Down
File renamed without changes.
21 changes: 5 additions & 16 deletions docs/pages/plugins/frontmatter.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -8,26 +8,15 @@ import { faGithub } from '@fortawesome/free-brands-svg-icons';

<PackageDescription pjson={pjson} />

## Overview

This plugin is designed to prepend a YAML frontmatter block to the content of each page generated by TypeDoc. This metadata can be used to configure the page's appearance, layout, and other properties depending on the host platform.

## Features

- Apply global frontmatter variables to all pages.
- Configure specific pages with comment tags.

## Installation

```sh npm2yarn
npm install typedoc-plugin-frontmatter@next --save-dev
```

## Usage

```json filename="typedoc.json"
{
"plugin": ["typedoc-plugin-markdown", "typedoc-plugin-frontmatter"]
}
```

Please see the [option guide](/plugins/frontmatter/options) for available configuration.
- Ability to customize the frontmatter using a local plugin.

## Examples

Expand Down
3 changes: 2 additions & 1 deletion docs/pages/plugins/frontmatter/_meta.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
export default {
'quick-start': '',
options: '',
guide: '',
customizing: '',
};

0 comments on commit 647d03b

Please sign in to comment.