ampproject / ampproject/worker-dom

amp-youtube, amp-facebook and more wiped out by sanitize

Open
#689 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
3.3k
Forks
154
PR merge metrics
No merged PRs in 30d

Description

When loading AMP-styled content via amp-script and xhr into an AMP-page, apparently all non-HTML-standard tags (amp-youtube, amp-facebook, amp-ad, amp-twitter ... ) are wiped out from markup.

Message:
[amp-script] Sanitize node: amp-facebook

AMP-validated gets removed when loaded from worker.

Is this intended? When yes: Why?
Can I prevent this behavior?

Thanks a lor
Jan

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the issue's amp-script and xhr path with an AMP page containing amp-facebook, amp-youtube, amp-ad, or amp-twitter, and inspect the sanitizer message for the removed node. Determine whether removing these non-standard AMP tags is intended and whether the project exposes a supported way to preserve them; done means the behavior and prevention or correction path are established.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
frontend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.