mirror of
https://github.com/idanoo/GoScrobble.git
synced 2024-11-25 09:55:15 +00:00
1 line
1.4 KiB
JSON
1 line
1.4 KiB
JSON
{"ast":null,"code":"var weakMemoize = function weakMemoize(func) {\n // $FlowFixMe flow doesn't include all non-primitive types as allowed for weakmaps\n var cache = new WeakMap();\n return function (arg) {\n if (cache.has(arg)) {\n // $FlowFixMe\n return cache.get(arg);\n }\n\n var ret = func(arg);\n cache.set(arg, ret);\n return ret;\n };\n};\n\nexport default weakMemoize;","map":{"version":3,"sources":["/app/node_modules/@emotion/weak-memoize/dist/weak-memoize.browser.esm.js"],"names":["weakMemoize","func","cache","WeakMap","arg","has","get","ret","set"],"mappings":"AAAA,IAAIA,WAAW,GAAG,SAASA,WAAT,CAAqBC,IAArB,EAA2B;AAC3C;AACA,MAAIC,KAAK,GAAG,IAAIC,OAAJ,EAAZ;AACA,SAAO,UAAUC,GAAV,EAAe;AACpB,QAAIF,KAAK,CAACG,GAAN,CAAUD,GAAV,CAAJ,EAAoB;AAClB;AACA,aAAOF,KAAK,CAACI,GAAN,CAAUF,GAAV,CAAP;AACD;;AAED,QAAIG,GAAG,GAAGN,IAAI,CAACG,GAAD,CAAd;AACAF,IAAAA,KAAK,CAACM,GAAN,CAAUJ,GAAV,EAAeG,GAAf;AACA,WAAOA,GAAP;AACD,GATD;AAUD,CAbD;;AAeA,eAAeP,WAAf","sourcesContent":["var weakMemoize = function weakMemoize(func) {\n // $FlowFixMe flow doesn't include all non-primitive types as allowed for weakmaps\n var cache = new WeakMap();\n return function (arg) {\n if (cache.has(arg)) {\n // $FlowFixMe\n return cache.get(arg);\n }\n\n var ret = func(arg);\n cache.set(arg, ret);\n return ret;\n };\n};\n\nexport default weakMemoize;\n"]},"metadata":{},"sourceType":"module"} |