2 ms·
I wish developers were more aware of ReplaceState, which updates the URL but deletes the previous state. I usually put a condition check in any state saving tha
by 1123581321 13y ago
I wish developers were more aware of ReplaceState, which updates the URL but deletes the previous state. I usually put a condition check in any state saving that checks to see which is more appropriate. For example, in a page of popup videos associated with URLs I might push the first state so the user can hit back once to get the normal URL, but replace from then on so the number of back actions to leave never exceeds two.