<link href="//maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" rel="stylesheet" id="bootstrap-css">
<script src="//maxcdn.bootstrapcdn.com/bootstrap/4.0.0/js/bootstrap.min.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" rel="stylesheet" id="bootstrap-css">
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/js/bootstrap.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/js/bootstrap.bundle.min.js"></script>
<script
src="https://code.jquery.com/jquery-3.3.1.min.js"
integrity="sha256-FgpCb/KJQlLNfOu91ta32o/NMZxltwRo8QtmkMRdAu8="
crossorigin="anonymous"></script>
<div class="container theme-showcase">
<h1>Calendar</h1>
<div id="holder" class="row" ></div>
</div>
<script type="text/tmpl" id="tmpl">
{{
var date = date || new Date(),
month = date.getMonth(),
year = date.getFullYear(),
first = new Date(year, month, 1),
last = new Date(year, month + 1, 0),
startingDay = first.getDay(),
thedate = new Date(year, month, 1 - startingDay),
dayclass = lastmonthcss,
today = new Date(),
i, j;
if (mode === 'week') {
thedate = new Date(date);
thedate.setDate(date.getDate() - date.getDay());
first = new Date(thedate);