The following code shows how to create nav pills.
<!DOCTYPE html>
<html>
<head>
<script type='text/javascript'
src='http://code.jquery.com/jquery-1.8.3.js'></script>
<script type='text/javascript'
src="http://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/2.1.0/bootstrap.min.js"></script>
<link rel="stylesheet" type="text/css"
href="http://netdna.bootstrapcdn.com/twitter-bootstrap/2.2.2/css/bootstrap-combined.min.css">
<style type='text/css'>
.subject-pill>a {
border-style: solid;
border-width: 1px;
}<!--from ww w . jav a2 s. co m-->
</style>
</head>
<body>
<ul class="nav nav-pills nav-stacked"
data-bind="foreach: childSubjects()">
<li class="subject-pill">
<a href="#">
<i class="pull-right icon-chevron-right"></i>
<i class="icon-remove icon-white" data-bind="visible: selected, clickBubble: false"></i>
<span> Some longer sample text</span>
</a></li>
</ul>
</body>
</html>