Skip to content

GitLab

  • Menu
Projects Groups Snippets
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • G g1
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 68
    • Issues 68
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 4
    • Merge requests 4
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • cto
  • g1
  • Issues
  • #158

Closed
Open
Created Mar 18, 2019 by Karmanya Aggarwal@karmanya.aggarwalDeveloper

url.update should support a `replace` parameter

currently with url.update we can add a key to the hash/query params, or update a key if it already exists. we cannot remove a key if it already exists, unless we explicitly call it with a del parameter, which only deletes. Thus we should have a replace parameter which can

  • add a key if it currently doesn't exist
  • remove a key if it exists in hash/search but not in the update object
  • update a key if it exists in both hash/search and update object with different values

?a=1&b=1.update({b:2}, 'replace') -> ?b=2

places this would be useful eg - if we have a formhandler url in a vega spec or something similar, and want to update it on hashchange to the new hash, we currently have to hardcode a version of the url in code and update it on hashchange.

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking