File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed
packages/merge/src/typedefs-mergers Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -18,12 +18,13 @@ const getLinkDirectiveURL = (directive: DirectiveNode): string | undefined => {
1818} ;
1919
2020/**
21- * Directives are considered distinct if they have different names, or, if they
22- * are link directives with different URLs.
21+ * Directives by default do not carry distinctual metadata, thus are not
22+ * considered distinct by default by this function. However @link directives are
23+ * only considered distinct if they have different URLs.
2324 */
2425const isDirectiveMetadataDistinct = ( directiveA : DirectiveNode , directiveB : DirectiveNode ) => {
2526 const isLinkPair = isLinkDirective ( directiveA ) && isLinkDirective ( directiveB ) ;
26- return isLinkPair ? getLinkDirectiveURL ( directiveA ) !== getLinkDirectiveURL ( directiveB ) : true ;
27+ return isLinkPair ? getLinkDirectiveURL ( directiveA ) !== getLinkDirectiveURL ( directiveB ) : false ;
2728} ;
2829
2930const isMatchingDirective = ( a : DirectiveNode , b : DirectiveNode ) => a . name . value === b . name . value ;
You can’t perform that action at this time.
0 commit comments