Skip to content

Commit abf11c6

Browse files
committed
docs(website): add ABNF syntax highlighting
1 parent 484e447 commit abf11c6

5 files changed

Lines changed: 1237 additions & 2 deletions

File tree

THIRD-PARTY-LICENSES.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# Third-Party Licenses
2+
3+
## ABNF TextMate bundle
4+
5+
The FastCSV documentation website uses ABNF as its grammar notation.
6+
An ABNF TextMate bundle is used for proper rendering of the ABNF grammar.
7+
8+
- **Source**: https://github.com/sanssecours/ABNF.tmbundle
9+
- **License**: Apache License 2.0
10+
- **Copyright**: René Schwaiger
11+
12+
Full license text: https://www.apache.org/licenses/LICENSE-2.0

docs/astro.config.mjs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,13 @@ export default defineConfig({
105105
content: 'window.plausible=window.plausible||function(){(plausible.q=plausible.q||[]).push(arguments)},plausible.init=plausible.init||function(i){plausible.o=i||{}};plausible.init();'
106106
},
107107
],
108+
expressiveCode: {
109+
shiki: {
110+
langs: [
111+
JSON.parse(fs.readFileSync('./grammars/ABNF.tmLanguage.json', 'utf-8'))
112+
],
113+
},
114+
},
108115
}),
109116
]
110117
});

0 commit comments

Comments
 (0)