Skip to content

tilde (~) is not being percent-encoded and duplicates itself in href and url #3790

@digitalartcrew

Description

@digitalartcrew

This issue tracker is for Bug Reports and Feature Requests only.

Please direct requests for help to StackOverflow.
See http://bit.ly/UIR-SOF for details.

This is a (check one box):

  • [x ] Bug Report
  • Feature Request
  • General Query

My version of UI-Router is: (type version) 0.3.1

Bug Report

Current Behavior:

When setting a param with the value of a tilde ~ it is not percent ended and it duplicates in the url. For some example, I were to set myParam=~abc in the url it would display as pathName?myParam=~~abc and when using the param to make a subsequent query it would use the incorrect value.

Expected Behavior:

I expect when I set the param that it will be percent-encoded in url and href as /pathName?myParam=%7Eabc

Link to Plunker or stackblitz that reproduces the issue:

https://plnkr.co/edit/zhNFUDPPQeEMMo50Zt19
Screen Shot 2019-12-13 at 1 06 59 PM

  • [x ] I have already asked my question on StackOverflow and nobody could answer the question

https://stackoverflow.com/questions/59205703/how-do-i-prevent-angularjs-routing-from-encoding-a-url-parameter-with-a-tilde

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