Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix($compile): ensure that hidden input values are correct after hist…
…ory.back Due to the nature of some browser's PageCache/BFCache, returning to an Angular app sometimes causes `input[hidden]` elements to retain the last value that was stored before the page was navigated away from previously. This is particularly problematic if the input has an interpolated value. E.g. `<input type="hidden" value="{{ 1 + 2 }}">` since when the browser returns, instead of the original interpolation template, the HTML contains the previous value `<input type="hidden" value="3">`. This commit instructs the browser not to attempt to reinstate the previous value when navigating back in history by setting `autocomplete="off"` on the hidden input element element.
- Loading branch information