UNPKG

795 BSource Map (JSON)View Raw
1{"version":3,"names":["isArrayEqual","a","b","length","every","it","index"],"sources":["isArrayEqual.tsx"],"sourcesContent":["/**\n * Compare two arrays with primitive values as the content.\n * We need to make sure that both values and order match.\n */\nexport default function isArrayEqual(a: any[], b: any[]) {\n if (a === b) {\n return true;\n }\n\n if (a.length !== b.length) {\n return false;\n }\n\n return a.every((it, index) => it === b[index]);\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA,eAAe,SAASA,YAAT,CAAsBC,CAAtB,EAAgCC,CAAhC,EAA0C;EACvD,IAAID,CAAC,KAAKC,CAAV,EAAa;IACX,OAAO,IAAP;EACD;;EAED,IAAID,CAAC,CAACE,MAAF,KAAaD,CAAC,CAACC,MAAnB,EAA2B;IACzB,OAAO,KAAP;EACD;;EAED,OAAOF,CAAC,CAACG,KAAF,CAAQ,CAACC,EAAD,EAAKC,KAAL,KAAeD,EAAE,KAAKH,CAAC,CAACI,KAAD,CAA/B,CAAP;AACD"}
\No newline at end of file