Canonical Links From Scratch with Rails Discussion
Really useful walkthrough—the url_for and content_for approach keeps canonical links simple, flexible, and easy to maintain without adding another dependency.
I think the best solution is to make canonical URL generation consistent and automatic wherever possible. Developers should also test canonical Friday Night Funkin tags carefully after deployment.