mirror of
https://github.com/FuelLabs/sway.git
synced 2025-08-08 20:58:27 +00:00
Add some missing keywords for mdBook syntax highlighting (#2903)
Add some missing keywords to the `sway.js` file. This was triggered by @Braqzen noticing some inconsistent highlighting in the generated MD books. Doesn't address custom types not being highlighted but that can be for a future PR.
This commit is contained in:
parent
49b9e7e5a3
commit
58f2021ad0
2 changed files with 12 additions and 3 deletions
|
@ -25,19 +25,24 @@ export default function(hljs) {
|
|||
"abi",
|
||||
"as",
|
||||
"asm",
|
||||
"break",
|
||||
"const",
|
||||
"continue",
|
||||
"contract",
|
||||
"dep",
|
||||
"deref",
|
||||
"else",
|
||||
"enum",
|
||||
"fn",
|
||||
"for",
|
||||
"if",
|
||||
"impl",
|
||||
"let",
|
||||
"library",
|
||||
"match",
|
||||
"mut",
|
||||
"else",
|
||||
"predicate",
|
||||
"pub",
|
||||
"ref",
|
||||
"return",
|
||||
"script",
|
||||
|
@ -54,6 +59,10 @@ export default function(hljs) {
|
|||
const LITERALS = [
|
||||
"true",
|
||||
"false",
|
||||
"Some",
|
||||
"None",
|
||||
"Ok",
|
||||
"Err",
|
||||
];
|
||||
const BUILTINS = [
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue