Bootstrap Navbar items after X amount place in dropdown



This is a question regarding how to approach something I have built. I have an admin where you can create lots of links that are then placed in the bootstrap nav but is there a way to put the items in a dropdown automatically after 6 items? Akmost paginate it?


Link | Link | Link | Link | Link | Link | Dropdown

Thanks in advance

Note: Might be in the wrong section