mirror of
https://github.com/facebook/docusaurus.git
synced 2025-05-18 19:46:57 +02:00
docs: clarify additionalLanguages with custom language definitions. (#8307)
Co-authored-by: Joshua Chen <sidachen2003@gmail.com> Co-authored-by: sebastienlorber <lorber.sebastien@gmail.com>
This commit is contained in:
parent
5c09dbfc3d
commit
32dc1eddba
1 changed files with 2 additions and 0 deletions
|
@ -136,6 +136,8 @@ const prismIncludeLanguages = (Prism) => {
|
||||||
|
|
||||||
You can refer to [Prism's official language definitions](https://github.com/PrismJS/prism/tree/master/components) when you are writing your own language definitions.
|
You can refer to [Prism's official language definitions](https://github.com/PrismJS/prism/tree/master/components) when you are writing your own language definitions.
|
||||||
|
|
||||||
|
When adding a custom language definition, you do not need to add the language to the `additionalLanguages` config array, since Docusaurus only looks up the `additionalLanguages` strings in languages that Prism provides. Adding the language import in `prism-include-languages.js` is sufficient.
|
||||||
|
|
||||||
## Line highlighting {#line-highlighting}
|
## Line highlighting {#line-highlighting}
|
||||||
|
|
||||||
### Highlighting with comments {#highlighting-with-comments}
|
### Highlighting with comments {#highlighting-with-comments}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue