Skip to content

Add test for JSONP #31765

Closed
Closed

Description

@mhevery

JSONP is a way to get data across domains by inserting a script tag.

client app inserts this into DOM

<script src="https://status.github.com/api/status.json?callback=apiStatus"></script>

it also publishes apiStatus

window.apiStatus = function(data) { ... }

The server then responds with:

apiStatus({"Name": "Foo", "Id": 1234, "Rank": 7});

Because Script tag gets inserted there is a async side-effect which will escape the zone.

Activity

  1. petebacondarwin commented on Feb 20, 2015

    @petebacondarwin
    Contributor

    If we have control over the callback then the zone can be set up there right?

  2. btford commented on Feb 20, 2015

    @btford
    Contributor

    @petebacondarwin – yes, but that would mean that you can't drop in your favorite library and have it "just work"

  3. self-assigned this
    on Feb 20, 2015
  4. mhevery commented on Feb 20, 2015

    @mhevery
    ContributorAuthor

    @btford do you have idea of how this could be intercepted?

  5. btford commented on Feb 20, 2015

    @btford
    Contributor

    I'm trying a few approaches now.

  6. added
    area: zones
    on Jul 21, 2019
  7. added this to the needsTriage milestone on Jul 21, 2019
  8. mhevery commented on Nov 3, 2020

    @mhevery
    ContributorAuthor

    Will not fix, as not feasible.

  9. angular-automatic-lock-bot commented on Dec 4, 2020

    @angular-automatic-lock-bot

    This issue has been automatically locked due to inactivity.
    Please file a new issue if you are encountering a similar or related problem.

    Read more about our automatic conversation locking policy.

    This action has been performed automatically by a bot.

  10. locked and limited conversation to collaborators on Dec 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area: zones

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions