Skip to content

Commit

Permalink
Add highlightjs support for Arturo (#7030)
Browse files Browse the repository at this point in the history
* Add highlightjs support for Arturo

* Fix yarn test
  • Loading branch information
ErikSchierboom authored Aug 15, 2024
1 parent 98e775e commit 955e23a
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 1 deletion.
2 changes: 2 additions & 0 deletions app/javascript/utils/highlight.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,11 @@ import setupRed from 'highlightjs-redbol'
import setupChapel from 'highlightjs-chapel'
import setupGDScript from '@exercism/highlightjs-gdscript'
import setupJq from 'highlightjs-jq'
import setupArturo from '@exercism/highlightjs-arturo'

if (isLookbehindSupported()) {
highlighter.default.registerLanguage('abap', setupABAP)
highlighter.default.registerLanguage('arturo', setupArturo)
highlighter.default.registerLanguage('cobol', setupCobol)
highlighter.default.registerLanguage('bqn', setupBqn)
highlighter.default.registerLanguage('zig', setupZig)
Expand Down
2 changes: 1 addition & 1 deletion jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ const config = {
'^.+\\.[t|j]sx?$': 'babel-jest',
},
transformIgnorePatterns: [
'node_modules/(?!(highlightjs-(bqn|zig|chapel|jq)|@ballerina/highlightjs-ballerina)/)',
'node_modules/(?!(highlightjs-(bqn|zig|chapel|jq)|@ballerina/highlightjs-ballerina|@exercism/highlightjs-arturo)/)',
],
moduleNameMapper: {
'^[./a-zA-Z0-9$_-]+\\.svg$':
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
"@exercism/active-background": "^0.6.2",
"@exercism/codemirror-lang-gleam": "^2.0.1",
"@exercism/codemirror-lang-wren": "https://github.com/exercism/codemirror-lang-wren",
"@exercism/highlightjs-arturo": "^0.0.2",
"@exercism/highlightjs-gdscript": "^0.0.1",
"@exercism/twine2-story-format": "https://github.com/exercism/twine2-story-format.git",
"@gleam-lang/highlight.js-gleam": "^1.0.0",
Expand Down
5 changes: 5 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1485,6 +1485,11 @@
"@lezer/highlight" "^1.0.0"
"@lezer/lr" "^1.0.0"

"@exercism/highlightjs-arturo@^0.0.2":
version "0.0.2"
resolved "https://registry.yarnpkg.com/@exercism/highlightjs-arturo/-/highlightjs-arturo-0.0.2.tgz#a053ffebda0a97caeb99654e9a77b792e11176a7"
integrity sha512-GFb7zlGB0aGr7cEdMQFCZejDE6zuc3+lHpZCll7euuBf4fHRo2kpt2BhST6m1z/E+KK8oPY9n8RpXNkNFHJfsg==

"@exercism/highlightjs-gdscript@^0.0.1":
version "0.0.1"
resolved "https://registry.yarnpkg.com/@exercism/highlightjs-gdscript/-/highlightjs-gdscript-0.0.1.tgz#1b10f0b394d406f6f9309ad66eec801ee399e671"
Expand Down

0 comments on commit 955e23a

Please sign in to comment.