cowboy/jquery-bbq — Issue #36: removeState & param.fragment questions
Author: nlambert
Created: 2012-02-08 15:02:57+00:00
State: open

Hello Mr Alman,

I am currently merging two project. One that uses bbq and one that doesn't. I have a feeling I will have to convert the latter to bbq.

I have a question concerning removeState & param.fragment

My observations :

removeState seems to leave the leading hash when there's only one state.

1. (starting url) - example.com
2. (param.fragment) - example.com/#content=about
3. (removeState) - example.com/#

param.fragment seems to convert "already there" hashes to the a=b&c=d format

1. (starting url) - example.com/#content
2. (param.fragment) - example.com/#content=&modal=about
3. (removeState) - example.com/#content=

My question :

I can see why this is happening, but are there options to do otherwise? i.e. Remove leading hash if there are no more "states" & not convert existing hash?

Cheers