JSPM

highlightjs-eta

0.1.0
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 23
  • Score
    100M100P100Q61570F
  • License MIT

highlight.js syntax definition for Eta template engine

Package Exports

  • highlightjs-eta

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (highlightjs-eta) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

highlights-eta

Add syntax highlighting to the Eta template engine (EJS will probably work too)

Usage

Browser

Load the module after Highlight.js

<script type="text/javascript" src="/path/to/highlight.min.js"></script>
<script
  type="text/javascript"
  src="/path/to/highlightjs-eta/dist/eta.min.js"
></script>
<script type="text/javascript">
  hljs.initHighlightingOnLoad()
</script>

You can also load from a CDN:

<script
  type="text/javascript"
  src="https://unpkg.com/highlightjs-eta/dist/eta.min.js"
></script>

Node

var hljs = require("highlightjs")
var hljsRobotsTxt = require("highlightjs-robots-txt")

hljs.registerLanguage("robots-txt", hljsRobotsTxt)
hljs.initHighlightingOnLoad()

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

License

MIT