MCPcopy Create free account
hub / github.com/TruthHun/BookStack / makeMap

Function makeMap

static/vuejs/vue.esm.js:32–44  ·  view source on GitHub ↗

* Make a map and return a function for checking if a key * is in that map.

(
  str,
  expectsLowerCase
)

Source from the content-addressed store, hash-verified

30 * is in that map.
31 */
32function makeMap (
33 str,
34 expectsLowerCase
35) {
36 var map = Object.create(null);
37 var list = str.split(',');
38 for (var i = 0; i < list.length; i++) {
39 map[list[i]] = true;
40 }
41 return expectsLowerCase
42 ? function (val) { return map[val.toLowerCase()]; }
43 : function (val) { return map[val]; }
44}
45
46/**
47 * Check if a tag is a built-in tag.

Callers 3

vue.esm.jsFile · 0.70
createPatchFunctionFunction · 0.70
genStaticKeys$1Function · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected