Munter / netlify-plugin-checklinks

Netlify build plugin check your links and asset references
BSD 3-Clause "New" or "Revised" License
89 stars 9 forks source link

Allow shortened URLs #82

Open gpanders opened 4 years ago

gpanders commented 4 years ago

Right now, URLs such as

https://amzn.to/2Ve0TZG

will fail the build since it uses a permanent redirect. However, the redirected URL is much longer and uglier, so it is preferable to use the shortened URLs in these cases.

Munter commented 4 years ago

Good point. It probably makes sense to keep the current behavior for internal links, but I can see how external links can have this problem.

I'm not entirely sure how to know if a 301 is from a link shortener or just old content it'll redirects. I'd be happy to hear some ideas about that.

For now you can add a skip it todo match on the failing test to avoid this problem blocking your build