Skip to content

Conversation

milosb793
Copy link

In this pull request, I've added:

  1. Refactor ES6
  2. Add support for named routes

Example of usage:

Sometimes, we need different name than just element ID, so let's define object like:

let routes = {
   "nav-item1" : "this-is-item1-page",
   "nav-item2" : "this-is-item2-page",
   "nav-item3" : "this-is-item3-page",
};

So instead of #nav-item1 we'll have #this-is-item1-page in URL.

To enable this feature, you can just pass option named routeObject:

$('.nav-tabs').stickyTabs({routeObject : routes});

If this option is not passed, default elements IDs will be used.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant