CoolFace
Apppublic

admin08077/Githubgemini

sourceHugging Faceotherupdated 10mo agoView on Hugging Face
0likes
micromark-util-normalize-identifier-C9ANKk3v.js.map1 linesDownload Raw Back to assets
1{"version":3,"file":"micromark-util-normalize-identifier-C9ANKk3v.js","sources":["../../node_modules/micromark-util-normalize-identifier/index.js"],"sourcesContent":["/**\n * Normalize an identifier (as found in references, definitions).\n *\n * Collapses markdown whitespace, trim, and then lower- and uppercase.\n *\n * Some characters are considered “uppercase”, such as U+03F4 (`ϴ`), but if their\n * lowercase counterpart (U+03B8 (`θ`)) is uppercased will result in a different\n * uppercase character (U+0398 (`Θ`)).\n * So, to get a canonical form, we perform both lower- and uppercase.\n *\n * Using uppercase last makes sure keys will never interact with default\n * prototypal values (such as `constructor`): nothing in the prototype of\n * `Object` is uppercase.\n *\n * @param {string} value\n *   Identifier to normalize.\n * @returns {string}\n *   Normalized identifier.\n */\nexport function normalizeIdentifier(value) {\n  return (\n    value\n      // Collapse markdown whitespace.\n      .replace(/[\\t\\n\\r ]+/g, ' ')\n      // Trim.\n      .replace(/^ | $/g, '')\n      // Some characters are considered “uppercase”, but if their lowercase\n      // counterpart is uppercased will result in a different uppercase\n      // character.\n      // Hence, to get that form, we perform both lower- and uppercase.\n      // Upper case makes sure keys will not interact with default prototypal\n      // methods: no method is uppercase.\n      .toLowerCase()\n      .toUpperCase()\n  )\n}\n"],"names":["normalizeIdentifier","value"],"mappings":"AAmBO,SAASA,EAAoBC,EAAO,CACzC,OACEA,EAEG,QAAQ,cAAe,GAAG,EAE1B,QAAQ,SAAU,EAAE,EAOpB,YAAW,EACX,YAAW,CAElB","x_google_ignoreList":[0]}