https://github.com/highlightjs/highlightjs-lustre
Lustre language grammar for Highlight.js
https://github.com/highlightjs/highlightjs-lustre
Last synced: 3 months ago
JSON representation
Lustre language grammar for Highlight.js
- Host: GitHub
- URL: https://github.com/highlightjs/highlightjs-lustre
- Owner: highlightjs
- License: bsd-3-clause
- Created: 2019-12-14T20:23:02.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2022-02-25T21:01:05.000Z (almost 4 years ago)
- Last Synced: 2025-09-08T01:32:01.790Z (3 months ago)
- Language: JavaScript
- Size: 768 KB
- Stars: 2
- Watchers: 3
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGES.md
- License: LICENSE
Awesome Lists containing this project
README
`highlight.js` syntax definition for Lustre.
For more about highlight.js, see https://highlightjs.org/
For more about Lustre and reactive languages, see
http://www-verimag.imag.fr/DIST-TOOLS/SYNCHRONE/reactive-toolbox/
### Usage
Simply include the `highlight.js` script package in your webpage or node app, load up this module and apply it to `hljs`.
If you're not using a build system and just want to embed this in your webpage:
```html
hljs.registerLanguage('lustre', window.hljsDefineLustre);
hljs.highlightAll();
```
If you're using webpack / rollup / browserify / node:
```javascript
var hljs = require('highlightjs');
var hljsDefineLustre = require('highlightjs-lustre');
hljsDefineLustre(hljs);
hljs.highlightAll();
```
### Advanced
This is a pretty simple package, the only thing you might want to do differently is name the language something other than `lustre`. If you want to do this, simply `import { definer } from 'highlightjs-lustre';` and use it like: `hljs.registerLanguage('othername', definer);`.