gfranko / jquery.tocify.js

A jQuery Table of Contents plugin that can be themed with Twitter Bootstrap or jQueryUI.
http://gregfranko.com/jquery.tocify.js/
MIT License
927 stars 217 forks source link

Adding support for History.js #54

Closed actual-saurabh closed 10 years ago

actual-saurabh commented 10 years ago

fixes https://github.com/gfranko/jquery.tocify.js/issues/53

actual-saurabh commented 10 years ago

There's a lot of extraneous code that I have preserved from the previous history like implementation. If cleaned up, this can shorten the script, further.

gfranko commented 10 years ago

Sorry for taking so long to respond! I would prefer to not include another dependency (which is why I removed the History.js integration before). Why do you want to include it?

gfranko commented 10 years ago

Closing this issue for now, but I am willing to continue discussing it.

actual-saurabh commented 10 years ago

It actually isn't required for tocify, I confess. However, history doesn't work well, especially forward and back buttons. It'd be simpler to use an external library as dependency, IMHO, since it'd take care of history while tocify can focus on tocifying.

Practically, in terms of usage, a Table of Contents is pretty incomplete without proper history support.

gfranko commented 10 years ago

I hear what you're saying about trying to take any history management logic out of Tocify, but I don't think there is enough logic to warrant adding another dependency. I appreciate the pull request though.