Skip to content

State transition breaks ES6 Map when passed through optional $stateParams in a ui-sref #3189

Closed
@mrohr

Description

@mrohr

When using an ES6 Map as a optional state param in order to pass data from one state to another, the Map object's methods stop working once passed through to another state.

http://plnkr.co/edit/TVANV1Cnb8B7h95mNjmW?p=preview

in the plunkr, transitioning between states without passing any stateParams works, and just instantiates a new Map. If you click one of the links that passes the Map as a stateParam, the plunkr breaks with the error:

Method Map.prototype.<methodName> called on incompatible receiver #<Map>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions