Last active
March 4, 2020 20:23
-
-
Save neatshell/edecf727ace7b5b49518a8c371879687 to your computer and use it in GitHub Desktop.
document.querySelector* cheatsheet
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Get the canonical url of a page | |
document.querySelector("link[rel='canonical']").href; | |
document.querySelector("link[rel='canonical']").getAttribute("href"); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment