Skip to content

Commit

Permalink
docs: Updated README
Browse files Browse the repository at this point in the history
  • Loading branch information
nonara committed Dec 5, 2023
1 parent b3fab8d commit 8e4679f
Showing 1 changed file with 26 additions and 1 deletion.
27 changes: 26 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ _Migrating from ttypescript is easy! See: [Method 1: Live Compiler](#method-1-li
* [Program Transformer Entry Point](#program-transformer-entry-point)
* [Configuring Program Transformers](#configuring-program-transformers)
* [Program Transformer Example](#program-transformer-example)
* [Plugin Package Configuration](#plugin-package-configuration)
* [Example](#example)
* [Resources](#resources)
* [Recommended Reading](#recommended-reading)
* [Recommended Tools](#recommended-tools)
Expand Down Expand Up @@ -261,6 +263,29 @@ export default function (
[`{ transform: "@typescript-virtual-barrel/compiler-plugin", transformProgram: true }`](https://github.com/zaguiini/typescript-virtual-barrel)
## Plugin Package Configuration
The plugin package configuration allows you to specify custom options for your TypeScript plugin.
This configuration is defined in the `package.json` of your plugin under the `tsp` property.
An example use case is enabling `parseAllJsDoc` if you require full JSDoc parsing in tsc for your transformer in TS v5.3+. (see: [5.3 JSDoc parsing changes](https://devblogs.microsoft.com/typescript/announcing-typescript-5-3/#optimizations-by-skipping-jsdoc-parsing))
For all available options, see the `PluginPackageConfig` type in [plugin-types.ts](https://github.com/nonara/ts-patch/blob/master/projects/core/shared/plugin-types.ts)
### Example
```jsonc
{
"name": "your-plugin-name",
"version": "1.0.0",
"tsp": {
"tscOptions": {
"parseAllJsDoc": true
}
}
}
```
## Resources
### Recommended Reading
Expand Down Expand Up @@ -312,7 +337,7 @@ Cleans patch cache & lockfiles

## Help Wanted

If you're interested in helping and have a _high level_ of skill with the TS compiler API, please reach out!
If you're interested in helping and are knowledgeable with the TS compiler codebase, feel free to reach out!
# License
Expand Down

0 comments on commit 8e4679f

Please sign in to comment.