source: node_modules/highlight.js/lib/languages/erb.js

main
Last change on this file was d24f17c, checked in by Aleksandar Panovski <apano77@…>, 15 months ago

Initial commit

  • Property mode set to 100644
File size: 661 bytes
Line 
1/*
2Language: ERB (Embedded Ruby)
3Requires: xml.js, ruby.js
4Author: Lucas Mazza <lucastmazza@gmail.com>
5Contributors: Kassio Borges <kassioborgesm@gmail.com>
6Description: "Bridge" language defining fragments of Ruby in HTML within <% .. %>
7Website: https://ruby-doc.org/stdlib-2.6.5/libdoc/erb/rdoc/ERB.html
8Category: template
9*/
10
11/** @type LanguageFn */
12function erb(hljs) {
13 return {
14 name: 'ERB',
15 subLanguage: 'xml',
16 contains: [
17 hljs.COMMENT('<%#', '%>'),
18 {
19 begin: '<%[%=-]?',
20 end: '[%-]?%>',
21 subLanguage: 'ruby',
22 excludeBegin: true,
23 excludeEnd: true
24 }
25 ]
26 };
27}
28
29module.exports = erb;
Note: See TracBrowser for help on using the repository browser.