Skip to content

facebook: does not work, because right clicking the link undoes the change #43

@attila-lendvai

Description

@attila-lendvai

i was debugging the code, it runs fine, updates the link as expected, but when i right click the link, then something undoes the change.

console log while stepping through one page load (class attr deleted for brevity).

notice how a link node is changing its href from bad, to good, and then back again to bad.

rewriting fb link: <a href=​"https:​/​/​l.facebook.com/​l.php?u=https%3A%2F%2Fyoutu.be%2Fmk-q16k-x0Y%3Ff…ondmXVkc-TZotTfaW92r_9dXYpM6EeBYuFQi28tPJUdpTN7_ZRuGw9cCW4_pszQ9FvXC8uSQO0" rel=​"nofollow noopener" role=​"link" tabindex=​"0" target=​"_blank">​https://youtu.be/mk-q16k-x0Y​

temp1
<a href=​"https:​/​/​youtu.be/​mk-q16k-x0Y?fbclid=IwAR25ikVoQn_KieyHoZAtqc0n8HjjoS4sxUwuPdUxzDf6285jpgNnLw-I9gQ" rel=​"nofollow noopener" role=​"link" tabindex=​"0" target=​"_blank">​https://youtu.be/mk-q16k-x0Y​

temp2
<a href=​"https:​/​/​l.facebook.com/​l.php?u=https%3A%2F%2Fyoutu.be%2Fmk-q16k-x0Y%3Ff…ondmXVkc-TZotTfaW92r_9dXYpM6EeBYuFQi28tPJUdpTN7_ZRuGw9cCW4_pszQ9FvXC8uSQO0" rel=​"nofollow noopener" role=​"link" tabindex=​"0" target=​"_blank">​https://youtu.be/mk-q16k-x0Y​

temp1 == temp2
true

temp1
<a href=​"https:​/​/​l.facebook.com/​l.php?u=https%3A%2F%2Fyoutu.be%2Fmk-q16k-x0Y%3Ff…ondmXVkc-TZotTfaW92r_9dXYpM6EeBYuFQi28tPJUdpTN7_ZRuGw9cCW4_pszQ9FvXC8uSQO0" rel=​"nofollow noopener" role=​"link" tabindex=​"0" target=​"_blank">​https://youtu.be/mk-q16k-x0Y​

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions