UNPKG

prism-react-editor

Version:

Lightweight, extensible code editor component for React apps

28 lines (27 loc) 1.23 kB
import { l as languages } from "../../index-k28m3HFc.js"; import { c as clikePunctuation, e as clikeNumber, d as boolean, a as clikeComment } from "../../patterns-Cp3h1ylA-DIMdJT1M.js"; languages.reason = { "comment": clikeComment(), "string": { pattern: /"(?:\\[^]|[^\\\n"])*"/g, greedy: true }, "char": { pattern: /'(?:\\x[a-f\d]{2}|\\o[0-3][0-7][0-7]|\\\d{3}|\\.|[^\\\n'])'/g, greedy: true }, // Negative look-ahead prevents from matching things like String.capitalize "constructor": /\b[A-Z]\w*\b(?!\s*\.)/, "label": { pattern: /\b[a-z]\w*(?=::)/, alias: "symbol" }, // 'class-name' must be matched *after* 'constructor' defined below "class-name": /\b[A-Z]\w*/, "keyword": /\b(?:and|as|assert|begin|class|constraint|do|done|downto|else|end|exception|external|f?or|fun|function|functor|if|in|include|inherit|initializer|lazy|let|method|module|mutable|new|nonrec|object|of|open|private|rec|sig|struct|switch|[tw]hen|to|try|type|val|virtual|while|with)\b/, "boolean": boolean, "number": clikeNumber, "operator": /\.{3}|:[:=]|[|-]>|=>|==?=?|<=?|>=?|[|^?'#!~`]|[/*+-]\.?|\b(?:asr|land|ls[lr]|lx?or|mod)\b/, "punctuation": clikePunctuation }; //# sourceMappingURL=reason.js.map