chapter-and-verse
Version:
Given a bible reference, validates it and returns an object with book, chapter, verse and more
18 lines (17 loc) • 425 B
HTML
<html lang="en">
<head>
<meta charset="UTF-8">
<title>chapter-and-verse</title>
<script src="chapterAndVerse.js"></script>
</head>
<body>
<div id="input">Gn 3:2-4</div>
<div id="output"></div>
<script>
const text = document.getElementById('input').innerText
const el = document.getElementById('output')
el.innerText = chapterAndVerse(text).toSimpleObject().asShortString
</script>
</body>
</html>