@graphitation/apollo-react-relay-duct-tape 1.0.31 → 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.eslintcache +1 -1
- package/CHANGELOG.md +11 -2
- package/lib/storeObservation/shallowCompareFragmentReferences.d.ts +1 -1
- package/lib/storeObservation/shallowCompareFragmentReferences.d.ts.map +1 -1
- package/lib/storeObservation/shallowCompareFragmentReferences.js.map +1 -1
- package/lib/storeObservation/shallowCompareFragmentReferences.mjs.map +1 -1
- package/lib/types.d.ts +3 -3
- package/lib/types.d.ts.map +1 -1
- package/lib/types.js.map +1 -1
- package/package.json +2 -2
package/.eslintcache
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
[{"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/__tests__/hooks.test.tsx":"1","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/__tests__/useOverridenOrDefaultApolloClient.test.tsx":"2","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/convertFetchPolicy.ts":"3","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/hooks.ts":"4","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/index.ts":"5","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/__tests__/compiledHooks.test.tsx":"6","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/__tests__/fragmentReferencesFieldPolicy.test.ts":"7","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/__tests__/getPossibleTypesAndDataIdFromNode.test.ts":"8","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/__tests__/nodeFromCacheFieldPolicy.test.ts":"9","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/index.ts":"10","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/types.ts":"11","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useCompiledFragment.ts":"12","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useCompiledLazyLoadQuery.ts":"13","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useCompiledPaginationFragment.ts":"14","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useCompiledRefetchableFragment.ts":"15","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useDeepCompareMemoize.ts":"16","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useForceUpdate.ts":"17","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/fragmentReferencesFieldPolicy.ts":"18","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/getPossibleTypesAndDataIdFromNode.ts":"19","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/index.ts":"20","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/nodeFromCacheFieldPolicy.ts":"21","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/shallowCompareFragmentReferences.ts":"22","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/typePolicies.ts":"23","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/types.ts":"24","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/useOverridenOrDefaultApolloClient.ts":"25"},{"size":11195,"mtime":1709816566975,"results":"26","hashOfConfig":"27"},{"size":1917,"mtime":1709816566975,"results":"28","hashOfConfig":"27"},{"size":690,"mtime":1709816566975,"results":"29","hashOfConfig":"27"},{"size":12265,"mtime":1709816566975,"results":"30","hashOfConfig":"27"},{"size":174,"mtime":1709816566975,"results":"31","hashOfConfig":"27"},{"size":37593,"mtime":1709816566975,"results":"32","hashOfConfig":"27"},{"size":1839,"mtime":1709816566975,"results":"33","hashOfConfig":"27"},{"size":1709,"mtime":1709816566979,"results":"34","hashOfConfig":"27"},{"size":3041,"mtime":1709816566979,"results":"35","hashOfConfig":"27"},{"size":445,"mtime":1709816566979,"results":"36","hashOfConfig":"27"},{"size":575,"mtime":1709816566979,"results":"37","hashOfConfig":"27"},{"size":3668,"mtime":1709816566979,"results":"38","hashOfConfig":"27"},{"size":3662,"mtime":1709816566979,"results":"39","hashOfConfig":"27"},{"size":10442,"mtime":1709816566979,"results":"40","hashOfConfig":"27"},{"size":5414,"mtime":1709816566979,"results":"41","hashOfConfig":"27"},{"size":843,"mtime":1709816566979,"results":"42","hashOfConfig":"27"},{"size":152,"mtime":1709816566979,"results":"43","hashOfConfig":"27"},{"size":286,"mtime":1709816566979,"results":"44","hashOfConfig":"27"},{"size":1243,"mtime":1709816566979,"results":"45","hashOfConfig":"27"},{"size":230,"mtime":1709816566979,"results":"46","hashOfConfig":"27"},{"size":2829,"mtime":1709816566979,"results":"47","hashOfConfig":"27"},{"size":2322,"mtime":1709816566979,"results":"48","hashOfConfig":"27"},{"size":1110,"mtime":1709816566979,"results":"49","hashOfConfig":"27"},{"size":2058,"mtime":1709816566979,"results":"50","hashOfConfig":"27"},{"size":1314,"mtime":1709816566979,"results":"51","hashOfConfig":"27"},{"filePath":"52","messages":"53","suppressedMessages":"54","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"qqqdtw",{"filePath":"55","messages":"56","suppressedMessages":"57","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"58","messages":"59","suppressedMessages":"60","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"61","messages":"62","suppressedMessages":"63","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"64","messages":"65","suppressedMessages":"66","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"67","messages":"68","suppressedMessages":"69","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"70","messages":"71","suppressedMessages":"72","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"73","messages":"74","suppressedMessages":"75","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"76","messages":"77","suppressedMessages":"78","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"79","messages":"80","suppressedMessages":"81","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"82","messages":"83","suppressedMessages":"84","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"85","messages":"86","suppressedMessages":"87","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"88","messages":"89","suppressedMessages":"90","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"91","messages":"92","suppressedMessages":"93","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"94","messages":"95","suppressedMessages":"96","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"97","messages":"98","suppressedMessages":"99","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"100","messages":"101","suppressedMessages":"102","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"103","messages":"104","suppressedMessages":"105","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"106","messages":"107","suppressedMessages":"108","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"109","messages":"110","suppressedMessages":"111","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"112","messages":"113","suppressedMessages":"114","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"115","messages":"116","suppressedMessages":"117","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"118","messages":"119","suppressedMessages":"120","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"121","messages":"122","suppressedMessages":"123","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"124","messages":"125","suppressedMessages":"126","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/__tests__/hooks.test.tsx",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/__tests__/useOverridenOrDefaultApolloClient.test.tsx",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/convertFetchPolicy.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/hooks.ts",[],["127"],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/index.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/__tests__/compiledHooks.test.tsx",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/__tests__/fragmentReferencesFieldPolicy.test.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/__tests__/getPossibleTypesAndDataIdFromNode.test.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/__tests__/nodeFromCacheFieldPolicy.test.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/index.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/types.ts",[],["128"],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useCompiledFragment.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useCompiledLazyLoadQuery.ts",[],["129"],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useCompiledPaginationFragment.ts",[],["130","131","132","133","134"],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useCompiledRefetchableFragment.ts",[],["135"],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useDeepCompareMemoize.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useForceUpdate.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/fragmentReferencesFieldPolicy.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/getPossibleTypesAndDataIdFromNode.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/index.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/nodeFromCacheFieldPolicy.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/shallowCompareFragmentReferences.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/typePolicies.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/types.ts",[],["136","137"],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/useOverridenOrDefaultApolloClient.ts",[],["138"],{"ruleId":"139","severity":1,"message":"140","line":319,"column":38,"nodeType":"141","messageId":"142","endLine":319,"endColumn":41,"suggestions":"143","suppressions":"144"},{"ruleId":"139","severity":1,"message":"140","line":16,"column":32,"nodeType":"141","messageId":"142","endLine":16,"endColumn":35,"suggestions":"145","suppressions":"146"},{"ruleId":"139","severity":1,"message":"140","line":87,"column":28,"nodeType":"141","messageId":"142","endLine":87,"endColumn":31,"suggestions":"147","suppressions":"148"},{"ruleId":"139","severity":1,"message":"140","line":170,"column":24,"nodeType":"141","messageId":"142","endLine":170,"endColumn":27,"suggestions":"149","suppressions":"150"},{"ruleId":"139","severity":1,"message":"140","line":173,"column":4,"nodeType":"141","messageId":"142","endLine":173,"endColumn":7,"suggestions":"151","suppressions":"152"},{"ruleId":"139","severity":1,"message":"140","line":175,"column":30,"nodeType":"141","messageId":"142","endLine":175,"endColumn":33,"suggestions":"153","suppressions":"154"},{"ruleId":"139","severity":1,"message":"140","line":185,"column":24,"nodeType":"141","messageId":"142","endLine":185,"endColumn":27,"suggestions":"155","suppressions":"156"},{"ruleId":"139","severity":1,"message":"140","line":221,"column":9,"nodeType":"141","messageId":"142","endLine":221,"endColumn":12,"suggestions":"157","suppressions":"158"},{"ruleId":"139","severity":1,"message":"140","line":38,"column":26,"nodeType":"141","messageId":"142","endLine":38,"endColumn":29,"suggestions":"159","suppressions":"160"},{"ruleId":"139","severity":1,"message":"140","line":5,"column":19,"nodeType":"141","messageId":"142","endLine":5,"endColumn":22,"suggestions":"161","suppressions":"162"},{"ruleId":"139","severity":1,"message":"140","line":10,"column":19,"nodeType":"141","messageId":"142","endLine":10,"endColumn":22,"suggestions":"163","suppressions":"164"},{"ruleId":"139","severity":1,"message":"140","line":17,"column":51,"nodeType":"141","messageId":"142","endLine":17,"endColumn":54,"suggestions":"165","suppressions":"166"},"@typescript-eslint/no-explicit-any","Unexpected any. Specify a different type.","TSAnyKeyword","unexpectedAny",["167","168"],["169"],["170","171"],["172"],["173","174"],["175"],["176","177"],["178"],["179","180"],["181"],["182","183"],["184"],["185","186"],["187"],["188","189"],["190"],["191","192"],["193"],["194","195"],["196"],["197","198"],["199"],["200","201"],["202"],{"messageId":"203","fix":"204","desc":"205"},{"messageId":"206","fix":"207","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"211","desc":"205"},{"messageId":"206","fix":"212","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"213","desc":"205"},{"messageId":"206","fix":"214","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"215","desc":"205"},{"messageId":"206","fix":"216","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"217","desc":"205"},{"messageId":"206","fix":"218","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"219","desc":"205"},{"messageId":"206","fix":"220","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"221","desc":"205"},{"messageId":"206","fix":"222","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"223","desc":"205"},{"messageId":"206","fix":"224","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"225","desc":"205"},{"messageId":"206","fix":"226","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"227","desc":"205"},{"messageId":"206","fix":"228","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"229","desc":"205"},{"messageId":"206","fix":"230","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"231","desc":"205"},{"messageId":"206","fix":"232","desc":"208"},{"kind":"209","justification":"210"},"suggestUnknown",{"range":"233","text":"234"},"Use `unknown` instead, this will force you to explicitly, and safely assert the type is correct.","suggestNever",{"range":"233","text":"235"},"Use `never` instead, this is useful when instantiating generic type parameters that you don't need to know the type of.","directive","",{"range":"236","text":"234"},{"range":"236","text":"235"},{"range":"237","text":"234"},{"range":"237","text":"235"},{"range":"238","text":"234"},{"range":"238","text":"235"},{"range":"239","text":"234"},{"range":"239","text":"235"},{"range":"240","text":"234"},{"range":"240","text":"235"},{"range":"241","text":"234"},{"range":"241","text":"235"},{"range":"242","text":"234"},{"range":"242","text":"235"},{"range":"243","text":"234"},{"range":"243","text":"235"},{"range":"244","text":"234"},{"range":"244","text":"235"},{"range":"245","text":"234"},{"range":"245","text":"235"},{"range":"246","text":"234"},{"range":"246","text":"235"},[11682,11685],"unknown","never",[567,570],[2626,2629],[5796,5799],[5897,5900],[5997,6000],[6286,6289],[7350,7353],[1283,1286],[158,161],[276,279],[455,458]]
|
|
1
|
+
[{"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/__tests__/hooks.test.tsx":"1","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/__tests__/useOverridenOrDefaultApolloClient.test.tsx":"2","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/convertFetchPolicy.ts":"3","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/hooks.ts":"4","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/index.ts":"5","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/__tests__/compiledHooks.test.tsx":"6","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/__tests__/fragmentReferencesFieldPolicy.test.ts":"7","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/__tests__/getPossibleTypesAndDataIdFromNode.test.ts":"8","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/__tests__/nodeFromCacheFieldPolicy.test.ts":"9","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/index.ts":"10","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/types.ts":"11","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useCompiledFragment.ts":"12","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useCompiledLazyLoadQuery.ts":"13","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useCompiledPaginationFragment.ts":"14","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useCompiledRefetchableFragment.ts":"15","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useDeepCompareMemoize.ts":"16","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useForceUpdate.ts":"17","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/fragmentReferencesFieldPolicy.ts":"18","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/getPossibleTypesAndDataIdFromNode.ts":"19","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/index.ts":"20","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/nodeFromCacheFieldPolicy.ts":"21","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/shallowCompareFragmentReferences.ts":"22","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/typePolicies.ts":"23","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/types.ts":"24","/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/useOverridenOrDefaultApolloClient.ts":"25"},{"size":11195,"mtime":1711399012992,"results":"26","hashOfConfig":"27"},{"size":1917,"mtime":1711399012992,"results":"28","hashOfConfig":"27"},{"size":690,"mtime":1711399012992,"results":"29","hashOfConfig":"27"},{"size":12265,"mtime":1711399012992,"results":"30","hashOfConfig":"27"},{"size":174,"mtime":1711399012992,"results":"31","hashOfConfig":"27"},{"size":37593,"mtime":1711399012992,"results":"32","hashOfConfig":"27"},{"size":1839,"mtime":1711399012992,"results":"33","hashOfConfig":"27"},{"size":1709,"mtime":1711399012992,"results":"34","hashOfConfig":"27"},{"size":3041,"mtime":1711399012992,"results":"35","hashOfConfig":"27"},{"size":445,"mtime":1711399012992,"results":"36","hashOfConfig":"27"},{"size":575,"mtime":1711399012992,"results":"37","hashOfConfig":"27"},{"size":3668,"mtime":1711399012992,"results":"38","hashOfConfig":"27"},{"size":3662,"mtime":1711399012992,"results":"39","hashOfConfig":"27"},{"size":10442,"mtime":1711399012992,"results":"40","hashOfConfig":"27"},{"size":5414,"mtime":1711399012992,"results":"41","hashOfConfig":"27"},{"size":843,"mtime":1711399012992,"results":"42","hashOfConfig":"27"},{"size":152,"mtime":1711399012992,"results":"43","hashOfConfig":"27"},{"size":286,"mtime":1711399012992,"results":"44","hashOfConfig":"27"},{"size":1243,"mtime":1711399012992,"results":"45","hashOfConfig":"27"},{"size":230,"mtime":1711399012992,"results":"46","hashOfConfig":"27"},{"size":2829,"mtime":1711399012992,"results":"47","hashOfConfig":"27"},{"size":2325,"mtime":1711399012992,"results":"48","hashOfConfig":"27"},{"size":1110,"mtime":1711399012992,"results":"49","hashOfConfig":"27"},{"size":2069,"mtime":1711399012992,"results":"50","hashOfConfig":"27"},{"size":1314,"mtime":1711399012992,"results":"51","hashOfConfig":"27"},{"filePath":"52","messages":"53","suppressedMessages":"54","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"qqqdtw",{"filePath":"55","messages":"56","suppressedMessages":"57","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"58","messages":"59","suppressedMessages":"60","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"61","messages":"62","suppressedMessages":"63","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"64","messages":"65","suppressedMessages":"66","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"67","messages":"68","suppressedMessages":"69","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"70","messages":"71","suppressedMessages":"72","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"73","messages":"74","suppressedMessages":"75","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"76","messages":"77","suppressedMessages":"78","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"79","messages":"80","suppressedMessages":"81","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"82","messages":"83","suppressedMessages":"84","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"85","messages":"86","suppressedMessages":"87","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"88","messages":"89","suppressedMessages":"90","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"91","messages":"92","suppressedMessages":"93","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"94","messages":"95","suppressedMessages":"96","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"97","messages":"98","suppressedMessages":"99","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"100","messages":"101","suppressedMessages":"102","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"103","messages":"104","suppressedMessages":"105","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"106","messages":"107","suppressedMessages":"108","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"109","messages":"110","suppressedMessages":"111","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"112","messages":"113","suppressedMessages":"114","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"115","messages":"116","suppressedMessages":"117","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"118","messages":"119","suppressedMessages":"120","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"121","messages":"122","suppressedMessages":"123","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"124","messages":"125","suppressedMessages":"126","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/__tests__/hooks.test.tsx",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/__tests__/useOverridenOrDefaultApolloClient.test.tsx",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/convertFetchPolicy.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/hooks.ts",[],["127"],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/index.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/__tests__/compiledHooks.test.tsx",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/__tests__/fragmentReferencesFieldPolicy.test.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/__tests__/getPossibleTypesAndDataIdFromNode.test.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/__tests__/nodeFromCacheFieldPolicy.test.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/index.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/types.ts",[],["128"],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useCompiledFragment.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useCompiledLazyLoadQuery.ts",[],["129"],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useCompiledPaginationFragment.ts",[],["130","131","132","133","134"],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useCompiledRefetchableFragment.ts",[],["135"],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useDeepCompareMemoize.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/compiledHooks/useForceUpdate.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/fragmentReferencesFieldPolicy.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/getPossibleTypesAndDataIdFromNode.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/index.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/nodeFromCacheFieldPolicy.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/shallowCompareFragmentReferences.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/storeObservation/typePolicies.ts",[],[],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/types.ts",[],["136","137"],"/mnt/vss/_work/1/s/packages/apollo-react-relay-duct-tape/src/useOverridenOrDefaultApolloClient.ts",[],["138"],{"ruleId":"139","severity":1,"message":"140","line":319,"column":38,"nodeType":"141","messageId":"142","endLine":319,"endColumn":41,"suggestions":"143","suppressions":"144"},{"ruleId":"139","severity":1,"message":"140","line":16,"column":32,"nodeType":"141","messageId":"142","endLine":16,"endColumn":35,"suggestions":"145","suppressions":"146"},{"ruleId":"139","severity":1,"message":"140","line":87,"column":28,"nodeType":"141","messageId":"142","endLine":87,"endColumn":31,"suggestions":"147","suppressions":"148"},{"ruleId":"139","severity":1,"message":"140","line":170,"column":24,"nodeType":"141","messageId":"142","endLine":170,"endColumn":27,"suggestions":"149","suppressions":"150"},{"ruleId":"139","severity":1,"message":"140","line":173,"column":4,"nodeType":"141","messageId":"142","endLine":173,"endColumn":7,"suggestions":"151","suppressions":"152"},{"ruleId":"139","severity":1,"message":"140","line":175,"column":30,"nodeType":"141","messageId":"142","endLine":175,"endColumn":33,"suggestions":"153","suppressions":"154"},{"ruleId":"139","severity":1,"message":"140","line":185,"column":24,"nodeType":"141","messageId":"142","endLine":185,"endColumn":27,"suggestions":"155","suppressions":"156"},{"ruleId":"139","severity":1,"message":"140","line":221,"column":9,"nodeType":"141","messageId":"142","endLine":221,"endColumn":12,"suggestions":"157","suppressions":"158"},{"ruleId":"139","severity":1,"message":"140","line":38,"column":26,"nodeType":"141","messageId":"142","endLine":38,"endColumn":29,"suggestions":"159","suppressions":"160"},{"ruleId":"139","severity":1,"message":"140","line":5,"column":19,"nodeType":"141","messageId":"142","endLine":5,"endColumn":22,"suggestions":"161","suppressions":"162"},{"ruleId":"139","severity":1,"message":"140","line":10,"column":19,"nodeType":"141","messageId":"142","endLine":10,"endColumn":22,"suggestions":"163","suppressions":"164"},{"ruleId":"139","severity":1,"message":"140","line":17,"column":51,"nodeType":"141","messageId":"142","endLine":17,"endColumn":54,"suggestions":"165","suppressions":"166"},"@typescript-eslint/no-explicit-any","Unexpected any. Specify a different type.","TSAnyKeyword","unexpectedAny",["167","168"],["169"],["170","171"],["172"],["173","174"],["175"],["176","177"],["178"],["179","180"],["181"],["182","183"],["184"],["185","186"],["187"],["188","189"],["190"],["191","192"],["193"],["194","195"],["196"],["197","198"],["199"],["200","201"],["202"],{"messageId":"203","fix":"204","desc":"205"},{"messageId":"206","fix":"207","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"211","desc":"205"},{"messageId":"206","fix":"212","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"213","desc":"205"},{"messageId":"206","fix":"214","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"215","desc":"205"},{"messageId":"206","fix":"216","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"217","desc":"205"},{"messageId":"206","fix":"218","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"219","desc":"205"},{"messageId":"206","fix":"220","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"221","desc":"205"},{"messageId":"206","fix":"222","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"223","desc":"205"},{"messageId":"206","fix":"224","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"225","desc":"205"},{"messageId":"206","fix":"226","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"227","desc":"205"},{"messageId":"206","fix":"228","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"229","desc":"205"},{"messageId":"206","fix":"230","desc":"208"},{"kind":"209","justification":"210"},{"messageId":"203","fix":"231","desc":"205"},{"messageId":"206","fix":"232","desc":"208"},{"kind":"209","justification":"210"},"suggestUnknown",{"range":"233","text":"234"},"Use `unknown` instead, this will force you to explicitly, and safely assert the type is correct.","suggestNever",{"range":"233","text":"235"},"Use `never` instead, this is useful when instantiating generic type parameters that you don't need to know the type of.","directive","",{"range":"236","text":"234"},{"range":"236","text":"235"},{"range":"237","text":"234"},{"range":"237","text":"235"},{"range":"238","text":"234"},{"range":"238","text":"235"},{"range":"239","text":"234"},{"range":"239","text":"235"},{"range":"240","text":"234"},{"range":"240","text":"235"},{"range":"241","text":"234"},{"range":"241","text":"235"},{"range":"242","text":"234"},{"range":"242","text":"235"},{"range":"243","text":"234"},{"range":"243","text":"235"},{"range":"244","text":"234"},{"range":"244","text":"235"},{"range":"245","text":"234"},{"range":"245","text":"235"},{"range":"246","text":"234"},{"range":"246","text":"235"},[11682,11685],"unknown","never",[567,570],[2626,2629],[5796,5799],[5897,5900],[5997,6000],[6286,6289],[7350,7353],[1283,1286],[158,161],[276,279],[455,458]]
|
package/CHANGELOG.md
CHANGED
|
@@ -1,12 +1,21 @@
|
|
|
1
1
|
# Change Log - @graphitation/apollo-react-relay-duct-tape
|
|
2
2
|
|
|
3
|
-
This log was last generated on
|
|
3
|
+
This log was last generated on Mon, 25 Mar 2024 20:42:20 GMT and should not be manually modified.
|
|
4
4
|
|
|
5
5
|
<!-- Start content -->
|
|
6
6
|
|
|
7
|
+
## 1.1.0
|
|
8
|
+
|
|
9
|
+
Mon, 25 Mar 2024 20:42:20 GMT
|
|
10
|
+
|
|
11
|
+
### Minor changes
|
|
12
|
+
|
|
13
|
+
- align generated types with relay-compiler >=15.0.0 (dragoshomner@microsoft.com)
|
|
14
|
+
- Bump @graphitation/apollo-react-relay-duct-tape-compiler to v1.5.0
|
|
15
|
+
|
|
7
16
|
## 1.0.31
|
|
8
17
|
|
|
9
|
-
Thu, 07 Mar 2024 13:08:
|
|
18
|
+
Thu, 07 Mar 2024 13:08:30 GMT
|
|
10
19
|
|
|
11
20
|
### Patches
|
|
12
21
|
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
*/
|
|
22
22
|
export declare function shallowCompareFragmentReferences<K extends string, ComparatorParam extends {
|
|
23
23
|
[key in K]: {
|
|
24
|
-
" $
|
|
24
|
+
" $fragmentSpreads": unknown;
|
|
25
25
|
};
|
|
26
26
|
}>(...fragmentReferenceProps: K[]): (prevProps: ComparatorParam, nextProps: ComparatorParam) => boolean;
|
|
27
27
|
//# sourceMappingURL=shallowCompareFragmentReferences.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"shallowCompareFragmentReferences.d.ts","sourceRoot":"","sources":["../../src/storeObservation/shallowCompareFragmentReferences.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAWH;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,gCAAgC,CAC9C,CAAC,SAAS,MAAM,EAChB,eAAe,SAAS;KAAG,GAAG,IAAI,CAAC,GAAG;QAAE,
|
|
1
|
+
{"version":3,"file":"shallowCompareFragmentReferences.d.ts","sourceRoot":"","sources":["../../src/storeObservation/shallowCompareFragmentReferences.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAWH;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,gCAAgC,CAC9C,CAAC,SAAS,MAAM,EAChB,eAAe,SAAS;KAAG,GAAG,IAAI,CAAC,GAAG;QAAE,mBAAmB,EAAE,OAAO,CAAA;KAAE;CAAE,EAExE,GAAG,sBAAsB,EAAE,CAAC,EAAE,GAC7B,CAAC,SAAS,EAAE,eAAe,EAAE,SAAS,EAAE,eAAe,KAAK,OAAO,CA8BrE"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/storeObservation/shallowCompareFragmentReferences.ts"],
|
|
4
|
-
"sourcesContent": ["/**\n * Modified from https://github.com/facebook/react/blob/201af81b0168cabea3cc07cd8201378a4fec4aaf/packages/shared/shallowEqual.js\n * Copying is the suggested way, as mentioned here https://github.com/facebook/react/issues/16919\n */\n\n/**\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found at\n * https://github.com/facebook/react/blob/201af81b0168cabea3cc07cd8201378a4fec4aaf/LICENSE\n */\n\nimport invariant from \"invariant\";\n\n/**\n * A custom React.memo() comparator function factory that can be used with\n * components that use `useFragment` on a GraphQL type that implements the\n * `Node` interface, in which case only the `id` value needs to be equal to\n * avoid a re-render.\n *\n * @todo\n * Support arrays with fragment references\n *\n * @param fragmentReferenceProps\n * The props that refer to fragment references and should only be compared by\n * their [Node] ids.\n *\n * @returns\n * A comparator with parameters typed such that TS can verify the component\n * passed to React.memo() has props that match.\n */\nexport function shallowCompareFragmentReferences<\n K extends string,\n ComparatorParam extends { [key in K]: { \" $
|
|
4
|
+
"sourcesContent": ["/**\n * Modified from https://github.com/facebook/react/blob/201af81b0168cabea3cc07cd8201378a4fec4aaf/packages/shared/shallowEqual.js\n * Copying is the suggested way, as mentioned here https://github.com/facebook/react/issues/16919\n */\n\n/**\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found at\n * https://github.com/facebook/react/blob/201af81b0168cabea3cc07cd8201378a4fec4aaf/LICENSE\n */\n\nimport invariant from \"invariant\";\n\n/**\n * A custom React.memo() comparator function factory that can be used with\n * components that use `useFragment` on a GraphQL type that implements the\n * `Node` interface, in which case only the `id` value needs to be equal to\n * avoid a re-render.\n *\n * @todo\n * Support arrays with fragment references\n *\n * @param fragmentReferenceProps\n * The props that refer to fragment references and should only be compared by\n * their [Node] ids.\n *\n * @returns\n * A comparator with parameters typed such that TS can verify the component\n * passed to React.memo() has props that match.\n */\nexport function shallowCompareFragmentReferences<\n K extends string,\n ComparatorParam extends { [key in K]: { \" $fragmentSpreads\": unknown } },\n>(\n ...fragmentReferenceProps: K[]\n): (prevProps: ComparatorParam, nextProps: ComparatorParam) => boolean {\n return (prevProps, nextProps) => {\n if (Object.is(prevProps, nextProps)) {\n return true;\n }\n\n const keysPrev = Object.keys(prevProps);\n const keysNext = Object.keys(nextProps);\n\n if (keysPrev.length !== keysNext.length) {\n return false;\n }\n\n for (let i = 0; i < keysPrev.length; i++) {\n const checkKey = keysPrev[i] as K;\n if (\n !Object.prototype.hasOwnProperty.call(nextProps, checkKey) ||\n fragmentReferenceProps.includes(checkKey)\n ? !idsEqual(\n prevProps[checkKey] as { id?: unknown },\n nextProps[checkKey] as { id?: unknown },\n )\n : !Object.is(prevProps[checkKey], nextProps[checkKey])\n ) {\n return false;\n }\n }\n\n return true;\n };\n}\n\nfunction idsEqual(objA: { id?: unknown }, objB: { id?: unknown }) {\n invariant(\n objA.id && objB.id,\n \"Expected both fragment reference objects to have an id field\",\n );\n return objA.id === objB.id;\n}\n"],
|
|
5
5
|
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAYA,uBAAsB;AAmBf,SAAS,oCAIX,wBACkE;AACrE,SAAO,CAAC,WAAW,cAAc;AAC/B,QAAI,OAAO,GAAG,WAAW,SAAS,GAAG;AACnC,aAAO;AAAA,IACT;AAEA,UAAM,WAAW,OAAO,KAAK,SAAS;AACtC,UAAM,WAAW,OAAO,KAAK,SAAS;AAEtC,QAAI,SAAS,WAAW,SAAS,QAAQ;AACvC,aAAO;AAAA,IACT;AAEA,aAAS,IAAI,GAAG,IAAI,SAAS,QAAQ,KAAK;AACxC,YAAM,WAAW,SAAS,CAAC;AAC3B,UACE,CAAC,OAAO,UAAU,eAAe,KAAK,WAAW,QAAQ,KACzD,uBAAuB,SAAS,QAAQ,IACpC,CAAC;AAAA,QACC,UAAU,QAAQ;AAAA,QAClB,UAAU,QAAQ;AAAA,MACpB,IACA,CAAC,OAAO,GAAG,UAAU,QAAQ,GAAG,UAAU,QAAQ,CAAC,GACvD;AACA,eAAO;AAAA,MACT;AAAA,IACF;AAEA,WAAO;AAAA,EACT;AACF;AAEA,SAAS,SAAS,MAAwB,MAAwB;AAChE,uBAAAA;AAAA,IACE,KAAK,MAAM,KAAK;AAAA,IAChB;AAAA,EACF;AACA,SAAO,KAAK,OAAO,KAAK;AAC1B;",
|
|
6
6
|
"names": ["invariant"]
|
|
7
7
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/storeObservation/shallowCompareFragmentReferences.ts"],
|
|
4
|
-
"sourcesContent": ["/**\n * Modified from https://github.com/facebook/react/blob/201af81b0168cabea3cc07cd8201378a4fec4aaf/packages/shared/shallowEqual.js\n * Copying is the suggested way, as mentioned here https://github.com/facebook/react/issues/16919\n */\n\n/**\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found at\n * https://github.com/facebook/react/blob/201af81b0168cabea3cc07cd8201378a4fec4aaf/LICENSE\n */\n\nimport invariant from \"invariant\";\n\n/**\n * A custom React.memo() comparator function factory that can be used with\n * components that use `useFragment` on a GraphQL type that implements the\n * `Node` interface, in which case only the `id` value needs to be equal to\n * avoid a re-render.\n *\n * @todo\n * Support arrays with fragment references\n *\n * @param fragmentReferenceProps\n * The props that refer to fragment references and should only be compared by\n * their [Node] ids.\n *\n * @returns\n * A comparator with parameters typed such that TS can verify the component\n * passed to React.memo() has props that match.\n */\nexport function shallowCompareFragmentReferences<\n K extends string,\n ComparatorParam extends { [key in K]: { \" $
|
|
4
|
+
"sourcesContent": ["/**\n * Modified from https://github.com/facebook/react/blob/201af81b0168cabea3cc07cd8201378a4fec4aaf/packages/shared/shallowEqual.js\n * Copying is the suggested way, as mentioned here https://github.com/facebook/react/issues/16919\n */\n\n/**\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found at\n * https://github.com/facebook/react/blob/201af81b0168cabea3cc07cd8201378a4fec4aaf/LICENSE\n */\n\nimport invariant from \"invariant\";\n\n/**\n * A custom React.memo() comparator function factory that can be used with\n * components that use `useFragment` on a GraphQL type that implements the\n * `Node` interface, in which case only the `id` value needs to be equal to\n * avoid a re-render.\n *\n * @todo\n * Support arrays with fragment references\n *\n * @param fragmentReferenceProps\n * The props that refer to fragment references and should only be compared by\n * their [Node] ids.\n *\n * @returns\n * A comparator with parameters typed such that TS can verify the component\n * passed to React.memo() has props that match.\n */\nexport function shallowCompareFragmentReferences<\n K extends string,\n ComparatorParam extends { [key in K]: { \" $fragmentSpreads\": unknown } },\n>(\n ...fragmentReferenceProps: K[]\n): (prevProps: ComparatorParam, nextProps: ComparatorParam) => boolean {\n return (prevProps, nextProps) => {\n if (Object.is(prevProps, nextProps)) {\n return true;\n }\n\n const keysPrev = Object.keys(prevProps);\n const keysNext = Object.keys(nextProps);\n\n if (keysPrev.length !== keysNext.length) {\n return false;\n }\n\n for (let i = 0; i < keysPrev.length; i++) {\n const checkKey = keysPrev[i] as K;\n if (\n !Object.prototype.hasOwnProperty.call(nextProps, checkKey) ||\n fragmentReferenceProps.includes(checkKey)\n ? !idsEqual(\n prevProps[checkKey] as { id?: unknown },\n nextProps[checkKey] as { id?: unknown },\n )\n : !Object.is(prevProps[checkKey], nextProps[checkKey])\n ) {\n return false;\n }\n }\n\n return true;\n };\n}\n\nfunction idsEqual(objA: { id?: unknown }, objB: { id?: unknown }) {\n invariant(\n objA.id && objB.id,\n \"Expected both fragment reference objects to have an id field\",\n );\n return objA.id === objB.id;\n}\n"],
|
|
5
5
|
"mappings": ";AAYA,OAAO,eAAe;AAmBf,SAAS,oCAIX,wBACkE;AACrE,SAAO,CAAC,WAAW,cAAc;AAC/B,QAAI,OAAO,GAAG,WAAW,SAAS,GAAG;AACnC,aAAO;AAAA,IACT;AAEA,UAAM,WAAW,OAAO,KAAK,SAAS;AACtC,UAAM,WAAW,OAAO,KAAK,SAAS;AAEtC,QAAI,SAAS,WAAW,SAAS,QAAQ;AACvC,aAAO;AAAA,IACT;AAEA,aAAS,IAAI,GAAG,IAAI,SAAS,QAAQ,KAAK;AACxC,YAAM,WAAW,SAAS,CAAC;AAC3B,UACE,CAAC,OAAO,UAAU,eAAe,KAAK,WAAW,QAAQ,KACzD,uBAAuB,SAAS,QAAQ,IACpC,CAAC;AAAA,QACC,UAAU,QAAQ;AAAA,QAClB,UAAU,QAAQ;AAAA,MACpB,IACA,CAAC,OAAO,GAAG,UAAU,QAAQ,GAAG,UAAU,QAAQ,CAAC,GACvD;AACA,eAAO;AAAA,MACT;AAAA,IACF;AAEA,WAAO;AAAA,EACT;AACF;AAEA,SAAS,SAAS,MAAwB,MAAwB;AAChE;AAAA,IACE,KAAK,MAAM,KAAK;AAAA,IAChB;AAAA,EACF;AACA,SAAO,KAAK,OAAO,KAAK;AAC1B;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/lib/types.d.ts
CHANGED
|
@@ -27,10 +27,10 @@ export type FetchPolicy = "store-or-network" | "store-and-network" | "network-on
|
|
|
27
27
|
* relay-compiler-language-typescript support for fragment references
|
|
28
28
|
*/
|
|
29
29
|
export interface _RefType<Ref extends string> {
|
|
30
|
-
" $
|
|
30
|
+
" $fragmentType": Ref;
|
|
31
31
|
}
|
|
32
32
|
export interface _FragmentRefs<Refs extends string> {
|
|
33
|
-
" $
|
|
33
|
+
" $fragmentSpreads": FragmentRefs<Refs>;
|
|
34
34
|
}
|
|
35
35
|
export type FragmentRefs<Refs extends string> = {
|
|
36
36
|
[ref in Refs]: true;
|
|
@@ -42,7 +42,7 @@ export type FragmentRef<Fragment> = Fragment extends _RefType<infer U> ? _Fragme
|
|
|
42
42
|
export type FragmentReference = unknown;
|
|
43
43
|
export type KeyType<TData = unknown> = Readonly<{
|
|
44
44
|
" $data"?: TData;
|
|
45
|
-
" $
|
|
45
|
+
" $fragmentSpreads": FragmentReference;
|
|
46
46
|
}>;
|
|
47
47
|
export type KeyTypeData<TKey extends KeyType<TData>, TData = unknown> = Required<TKey>[" $data"];
|
|
48
48
|
export type ArrayKeyType<TData = unknown> = ReadonlyArray<KeyType<ReadonlyArray<TData>> | null>;
|
package/lib/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAE5C,MAAM,WAAW,SAAS;IAExB,CAAC,IAAI,EAAE,MAAM,GAAG,GAAG,CAAC;CACrB;AAED,MAAM,WAAW,OAAO;IAEtB,CAAC,IAAI,EAAE,MAAM,GAAG,GAAG,CAAC;CACrB;AAED,MAAM,WAAW,aAAa;IAC5B,QAAQ,CAAC,SAAS,EAAE,SAAS,CAAC;IAC9B,QAAQ,CAAC,OAAO,CAAC,EAAE,OAAO,CAAC;IAC3B,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAC;IAC3B,QAAQ,CAAC,WAAW,CAAC,EAAE,OAAO,CAAC;CAChC;AAED,MAAM,MAAM,iBAAiB,GACzB;IACE,OAAO,EAAE,mBAAmB,CAAC;CAC9B,GACD,CAAC,YAAY,GAAG;IACd,kBAAkB,CAAC,EAAE,KAAK,CAAC;IAC3B,sBAAsB,CAAC,EAAE,YAAY,CAAC;IACtC,OAAO,CAAC,EAAE,KAAK,CAAC;CACjB,CAAC,GACF;IACE,kBAAkB,EAAE,YAAY,CAAC;IACjC,sBAAsB,CAAC,EAAE,YAAY,CAAC;IACtC,OAAO,CAAC,EAAE,KAAK,CAAC;CACjB,CAAC;AAEN,MAAM,MAAM,WAAW,GACnB,kBAAkB,GAClB,mBAAmB,GACnB,cAAc,GACd,YAAY,CAAC;AAEjB;;GAEG;AAEH,MAAM,WAAW,QAAQ,CAAC,GAAG,SAAS,MAAM;IAC1C,
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAE5C,MAAM,WAAW,SAAS;IAExB,CAAC,IAAI,EAAE,MAAM,GAAG,GAAG,CAAC;CACrB;AAED,MAAM,WAAW,OAAO;IAEtB,CAAC,IAAI,EAAE,MAAM,GAAG,GAAG,CAAC;CACrB;AAED,MAAM,WAAW,aAAa;IAC5B,QAAQ,CAAC,SAAS,EAAE,SAAS,CAAC;IAC9B,QAAQ,CAAC,OAAO,CAAC,EAAE,OAAO,CAAC;IAC3B,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAC;IAC3B,QAAQ,CAAC,WAAW,CAAC,EAAE,OAAO,CAAC;CAChC;AAED,MAAM,MAAM,iBAAiB,GACzB;IACE,OAAO,EAAE,mBAAmB,CAAC;CAC9B,GACD,CAAC,YAAY,GAAG;IACd,kBAAkB,CAAC,EAAE,KAAK,CAAC;IAC3B,sBAAsB,CAAC,EAAE,YAAY,CAAC;IACtC,OAAO,CAAC,EAAE,KAAK,CAAC;CACjB,CAAC,GACF;IACE,kBAAkB,EAAE,YAAY,CAAC;IACjC,sBAAsB,CAAC,EAAE,YAAY,CAAC;IACtC,OAAO,CAAC,EAAE,KAAK,CAAC;CACjB,CAAC;AAEN,MAAM,MAAM,WAAW,GACnB,kBAAkB,GAClB,mBAAmB,GACnB,cAAc,GACd,YAAY,CAAC;AAEjB;;GAEG;AAEH,MAAM,WAAW,QAAQ,CAAC,GAAG,SAAS,MAAM;IAC1C,gBAAgB,EAAE,GAAG,CAAC;CACvB;AAED,MAAM,WAAW,aAAa,CAAC,IAAI,SAAS,MAAM;IAChD,mBAAmB,EAAE,YAAY,CAAC,IAAI,CAAC,CAAC;CACzC;AAGD,MAAM,MAAM,YAAY,CAAC,IAAI,SAAS,MAAM,IAAI;KAC7C,GAAG,IAAI,IAAI,GAAG,IAAI;CACpB,CAAC;AAGF,MAAM,MAAM,WAAW,CAAC,QAAQ,IAAI,QAAQ,SAAS,QAAQ,CAAC,MAAM,CAAC,CAAC,GAClE,aAAa,CAAC,CAAC,CAAC,GAChB,KAAK,CAAC;AAEV;;GAEG;AAEH,MAAM,MAAM,iBAAiB,GAAG,OAAO,CAAC;AAExC,MAAM,MAAM,OAAO,CAAC,KAAK,GAAG,OAAO,IAAI,QAAQ,CAAC;IAC9C,QAAQ,CAAC,EAAE,KAAK,CAAC;IACjB,mBAAmB,EAAE,iBAAiB,CAAC;CACxC,CAAC,CAAC;AAEH,MAAM,MAAM,WAAW,CACrB,IAAI,SAAS,OAAO,CAAC,KAAK,CAAC,EAC3B,KAAK,GAAG,OAAO,IACb,QAAQ,CAAC,IAAI,CAAC,CAAC,QAAQ,CAAC,CAAC;AAE7B,MAAM,MAAM,YAAY,CAAC,KAAK,GAAG,OAAO,IAAI,aAAa,CAAC,OAAO,CAC/D,aAAa,CAAC,KAAK,CAAC,CACrB,GAAG,IAAI,CAAC,CAAC;AACV,MAAM,MAAM,gBAAgB,CAC1B,IAAI,SAAS,YAAY,CAAC,KAAK,CAAC,EAChC,KAAK,GAAG,OAAO,IACb,WAAW,CAAC,WAAW,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC"}
|
package/lib/types.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../src/types.ts"],
|
|
4
|
-
"sourcesContent": ["import type { DocumentNode } from \"graphql\";\n\nexport interface Variables {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n [name: string]: any;\n}\n\nexport interface Context {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n [name: string]: any;\n}\n\nexport interface OperationType {\n readonly variables: Variables;\n readonly context?: Context;\n readonly response: unknown;\n readonly rawResponse?: unknown;\n}\n\nexport type GraphQLTaggedNode =\n | {\n __brand: \"GraphQLTaggedNode\";\n }\n | (DocumentNode & {\n watchQueryDocument?: never;\n executionQueryDocument?: DocumentNode;\n __brand?: never;\n })\n | {\n watchQueryDocument: DocumentNode;\n executionQueryDocument?: DocumentNode;\n __brand?: never;\n };\n\nexport type FetchPolicy =\n | \"store-or-network\"\n | \"store-and-network\"\n | \"network-only\"\n | \"store-only\";\n\n/**\n * relay-compiler-language-typescript support for fragment references\n */\n\nexport interface _RefType<Ref extends string> {\n \" $
|
|
4
|
+
"sourcesContent": ["import type { DocumentNode } from \"graphql\";\n\nexport interface Variables {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n [name: string]: any;\n}\n\nexport interface Context {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n [name: string]: any;\n}\n\nexport interface OperationType {\n readonly variables: Variables;\n readonly context?: Context;\n readonly response: unknown;\n readonly rawResponse?: unknown;\n}\n\nexport type GraphQLTaggedNode =\n | {\n __brand: \"GraphQLTaggedNode\";\n }\n | (DocumentNode & {\n watchQueryDocument?: never;\n executionQueryDocument?: DocumentNode;\n __brand?: never;\n })\n | {\n watchQueryDocument: DocumentNode;\n executionQueryDocument?: DocumentNode;\n __brand?: never;\n };\n\nexport type FetchPolicy =\n | \"store-or-network\"\n | \"store-and-network\"\n | \"network-only\"\n | \"store-only\";\n\n/**\n * relay-compiler-language-typescript support for fragment references\n */\n\nexport interface _RefType<Ref extends string> {\n \" $fragmentType\": Ref;\n}\n\nexport interface _FragmentRefs<Refs extends string> {\n \" $fragmentSpreads\": FragmentRefs<Refs>;\n}\n\n// This is used in the actual artifacts to define the various fragment references a container holds.\nexport type FragmentRefs<Refs extends string> = {\n [ref in Refs]: true;\n};\n\n// This is a utility type for converting from a data type to a fragment reference that will resolve to that data type.\nexport type FragmentRef<Fragment> = Fragment extends _RefType<infer U>\n ? _FragmentRefs<U>\n : never;\n\n/**\n * react-relay DT\n */\n\nexport type FragmentReference = unknown;\n\nexport type KeyType<TData = unknown> = Readonly<{\n \" $data\"?: TData;\n \" $fragmentSpreads\": FragmentReference;\n}>;\n\nexport type KeyTypeData<\n TKey extends KeyType<TData>,\n TData = unknown,\n> = Required<TKey>[\" $data\"];\n\nexport type ArrayKeyType<TData = unknown> = ReadonlyArray<KeyType<\n ReadonlyArray<TData>\n> | null>;\nexport type ArrayKeyTypeData<\n TKey extends ArrayKeyType<TData>,\n TData = unknown,\n> = KeyTypeData<NonNullable<TKey[number]>>;\n"],
|
|
5
5
|
"mappings": ";;;;;;;;;;;;;;AAAA;AAAA;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@graphitation/apollo-react-relay-duct-tape",
|
|
3
3
|
"description": "A compatibility wrapper that provides the react-relay API on top of Apollo Client.",
|
|
4
4
|
"license": "MIT",
|
|
5
|
-
"version": "1.0
|
|
5
|
+
"version": "1.1.0",
|
|
6
6
|
"repository": {
|
|
7
7
|
"type": "git",
|
|
8
8
|
"url": "https://github.com/microsoft/graphitation.git",
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
"graphql": "^15.0.0",
|
|
31
31
|
"monorepo-scripts": "*",
|
|
32
32
|
"react": "^17.0.2",
|
|
33
|
-
"@graphitation/apollo-react-relay-duct-tape-compiler": "^1.
|
|
33
|
+
"@graphitation/apollo-react-relay-duct-tape-compiler": "^1.5.0",
|
|
34
34
|
"ts-expect": "^1.3.0"
|
|
35
35
|
},
|
|
36
36
|
"peerDependencies": {
|