-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: make theme work with default plugins and configuration
- Loading branch information
Showing
33 changed files
with
591 additions
and
1,143 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
## 0.2.0 (2024-08-08) | ||
|
||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,43 +1,70 @@ | ||
# Theme your TypeDoc like GitHub | ||
# typedoc-theme-gobstones | ||
|
||
[](https://npmjs.org/package/typedoc-github-theme) | ||
This a customized theme for [TypeDoc](https://typedoc.org/) used for all the generated documentation throughout the **GobstonesWeb2** project. | ||
It's based on the default theme used by TypeDoc, with mild improvements in readability and styling, and includes by default several plugins built-in so the user does not require to include them in their configuration. Included plugins are: | ||
* [typedoc-plugin-mdn-links](https://github.com/Gerrit0/typedoc-plugin-mdn-links) | ||
* [typedoc-plugin-merge-modules](https://github.com/krisztianb/typedoc-plugin-merge-modules) | ||
* [typedoc-plugin-remove-references](https://github.com/eyworldwide/typedoc-plugin-remove-references) | ||
* [typedoc-plugin-missing-exports](https://github.com/Gerrit0/typedoc-plugin-missing-exports) (With modifications) | ||
|
||
This [TypeDoc](https://github.com/TypeStrong/typedoc) theme is designed to provide an elegant and seamless look and feel for your TypeScript documentation on GitHub Pages, inspired by the GitHub design. | ||
[](https://github.com/gobstones/typedoc-theme-gobstones/blob/main/LICENSE) [](https://www.npmjs.com/package/@gobstones/typedoc-theme-gobstones) | ||
|
||
## Example | ||
[](https://gobstones.github.io/typedoc-theme-gobstones) | ||
|
||
[](https://killerjulian.github.io/typedoc-github-theme/) | ||
  | ||
|
||
## Usage | ||
## Install | ||
|
||
**Install the package with your favourite package manager:** | ||
This library is included in the [gobstones-scripts](https://gobstones.github.io/gobstones-scripts) library, and used in the provided TypeDoc configuration by default. If you are using `gobstones-scripts` you don't need to do anything to use this library. | ||
|
||
```text | ||
npm install typedoc-github-theme | ||
``` | ||
If you want to add this to a project that does not include `gobstones-scripts`, just install by using `npm`. | ||
|
||
```text | ||
pnpm install typedoc-github-theme | ||
```bash | ||
npm install @gobstones/typedoc-theme-gobstones | ||
``` | ||
|
||
```text | ||
yarn add typedoc-github-theme | ||
### Usage | ||
|
||
Again, if you are using `gobstones-scripts` with the default configuration you don't need to do anything. If you want to use in different type of project, or provide your custom configuration, read the following. | ||
|
||
Configure your project to use this theme by editing your `typedoc.config.js` file. Add the theme as a plugin, and set the theme to be `gobstones`. Additionally, configure properties for the default theme and plugins so the theme behaves as expected. | ||
|
||
```js | ||
module.exports = { | ||
// ... | ||
// You default configuration before this point | ||
plugin: [ | ||
// ... | ||
// Set up the theme, alongside your other plugins | ||
'@gobstones/typedoc-theme-gobstones' | ||
], | ||
excludeTags: [ | ||
// Remove the @internal from the excluded tags | ||
"@override", | ||
"@virtual", | ||
"@satisfies", | ||
"@overload", | ||
], | ||
visibilityFilters: { | ||
// Add @internal as a visibility filter | ||
'@internal': false, | ||
protected: false, | ||
private: false, | ||
inherited: false | ||
}, | ||
// Set `gobstones` as the theme | ||
theme: 'gobstones', | ||
// Configure the merge modules strategy as a module or module-category | ||
mergeModulesMergeMode: 'module' | ||
}; | ||
``` | ||
|
||
**Use the theme when generating your documentation:** | ||
|
||
```text | ||
typedoc src/** */ --plugin typedoc-github-theme --theme typedoc-github-theme | ||
``` | ||
|
||
--- | ||
|
||
## Author | ||
You should now be able to run `typedoc` command to get the documentation. If you are using `gobstones-scripts`, just execute `nps start doc` or one of it's related commands as usual. | ||
|
||
👤 **KillerJulian <[email protected]>** | ||
## Testing newer versions of the library | ||
|
||
- Github: [@KillerJulian](https://github.com/KillerJulian) | ||
To develop this library you will need to build the library and publish to a local repository, similar as to how you test `gobstones-scripts`. You may read about [how to setup a verdaccio server in your local environment](https://gobstones.github.io/gobstones-scripts/#md:testing-newer-versions-of-the-library) at the `gobstones-scripts` documentation, and if you have the gobstones-scripts project, you may even run the same server. | ||
|
||
## 🤝 Contributing | ||
## Contributing | ||
|
||
Contributions, issues and feature requests are welcome!<br />Feel free to check the [issues page](https://github.com/KillerJulian/typedoc-github-theme/issues). You can also take a look at the [contributing guide](https://github.com/KillerJulian/typedoc-github-theme/blob/master/CONTRIBUTING.md). | ||
See our [Contributions Guidelines](https://gobstones-github.io/gobstones-guidelines) to contribute. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.