The two \<link> types "preconnect" and "dns-prefetch" do not link to an actual resource but tell the browser to set up a connection with that site. They usually specify just the scheme and host (without a path) in the href.
Actual behaviour
Link checker tries to access the root of the domain and returns an error if there is nothing there (as there often won't be for sites that just host resources, the main target of preconnect).
Expected behaviour
Ignore \<link> elements with rel="preconnect" or rel="dns-prefetch" since they are specifying a site rather than a specific resource.
Example
The following site demonstrates this problem (unfortunately it's not an ideal testcase as it has so many links to check):
The two \<link> types "preconnect" and "dns-prefetch" do not link to an actual resource but tell the browser to set up a connection with that site. They usually specify just the scheme and host (without a path) in the href.
Actual behaviour
Link checker tries to access the root of the domain and returns an error if there is nothing there (as there often won't be for sites that just host resources, the main target of preconnect).
Expected behaviour
Ignore \<link> elements with rel="preconnect" or rel="dns-prefetch" since they are specifying a site rather than a specific resource.
Example
The following site demonstrates this problem (unfortunately it's not an ideal testcase as it has so many links to check):
https://www.smashingmagazine.com/