Skip to content
This repository has been archived by the owner on Apr 28, 2020. It is now read-only.

Commit

Permalink
Fixed back button behavior when using data-url feature.
Browse files Browse the repository at this point in the history
  • Loading branch information
Chris Ferdinandi committed Jan 18, 2014
1 parent 05101b1 commit efcd34f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@ A simple script to animate scrolling to anchor links. Easing support contributed
Getting started with Smooth Scroll is really easy. [View the online tutorial](http://cferdinandi.github.com/smooth-scroll/) or dig through the `index.html` file.

## Changelog
* v2.16 (Junuary 16, 2014)
* v2.17 (January 17, 2014)
* [Fixed back button behavior when using `data-url` feature.](https://github.com/cferdinandi/smooth-scroll/pull/18)
* v2.16 (January 16, 2014)
* [Updated variables for more accurate easing math when scrolling to top of page.](https://github.com/cferdinandi/smooth-scroll/pull/25#issuecomment-32566729)
* v2.15 (January 16, 2014)
* [Fixed bug that caused "scroll-to-top" animation to create endless loop.](https://github.com/cferdinandi/smooth-scroll/issues/24)
Expand Down
6 changes: 3 additions & 3 deletions smooth-scroll.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/* =============================================================
Smooth Scroll 2.16
Smooth Scroll 2.17
Animate scrolling to anchor links, by Chris Ferdinandi.
http://gomakethings.com
Expand Down Expand Up @@ -51,7 +51,7 @@
// Function to update URL
var updateURL = function (url, anchor) {
if ( url === 'true' && history.pushState ) {
history.pushState(null, null, '#' + anchor.id);
window.location.hash = '#' + anchor.id;
}
};

Expand Down Expand Up @@ -135,4 +135,4 @@

}

})();
})();

0 comments on commit efcd34f

Please sign in to comment.