Skip to content

[amp-script] Should text/javascript be allowed? #26259

Closed
@Malvoz

Description

<amp-script> requires a content-type of application/javascript when src is same-origin, which is documented in https://amp.dev/documentation/components/amp-script/#security-features. Should this be extended to allow text/javascript as well?

https://amp.dev serve scripts with text/javascript, and this HTTP Archive post suggests text/javascript is used widely.

Edit: Also, the HTML spec recommends use of text/javascript for script resources.

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions