UNPKG

@intlayer/core

Version:

Includes core Intlayer functions like translation, dictionary, and utility functions shared across multiple packages.

1 lines 642 B
{"version":3,"sources":["../../../src/utils/isSameKeyPath.ts"],"sourcesContent":["import type { KeyPath } from '../types';\n\ntype KeyPathWithKey = KeyPath & { key: string };\n\nexport const isSameKeyPath = (keyPath1: KeyPath[], keyPath2: KeyPath[]) =>\n keyPath1.every(\n (element, index) =>\n keyPath2[index] &&\n (keyPath2[index] as KeyPathWithKey).key ===\n (element as KeyPathWithKey).key &&\n keyPath2[index].type === element.type\n );\n"],"mappings":"AAIO,MAAM,gBAAgB,CAAC,UAAqB,aACjD,SAAS;AAAA,EACP,CAAC,SAAS,UACR,SAAS,KAAK,KACb,SAAS,KAAK,EAAqB,QACjC,QAA2B,OAC9B,SAAS,KAAK,EAAE,SAAS,QAAQ;AACrC;","names":[]}