Public
Edited
Feb 23, 2022
Importers
Insert cell
Insert cell
Insert cell
rst = {
let result = { bible: [] };
result.bible[0] = "Синодальный перевод (1876)";
for (let book of rst_json) {
const name = book.name;
const chap = name === "Псалтирь" ? "Псалом" : "Глава";
let chapters = book.chapters.map((ch) => {
const chn = `${chap} ${ch["verses"][0]["chapter"]}`;
let verses = ch["verses"].map((v) => v["text"].trim());
verses.unshift(chn);
return verses;
});
if (book.name === "Псалтирь") {
chapters.splice(-1);
}
if (book.name === "Даниил") {
chapters.splice(-2);
}
chapters.unshift(name);
result.bible.push(chapters);
}
return result;
}
Insert cell
kjv = {
let result = { bible: [] };
result.bible[0] = "King James Version";
for (let book of kjv_json) {
const name = book.name;
const chap = name === "Psalms" ? "Psalm" : "Chapter";
let chapters = book.chapters.map((ch) => {
const chn = `${chap} ${ch["verses"][0]["chapter"]}`;
let verses = ch["verses"].map((v) => v["text"].trim());
verses.unshift(chn);
return verses;
});
chapters.unshift(name);
result.bible.push(chapters);
}
return result;
}
Insert cell
kjv_json = (await d3.json(`https://jbbl.github.io/kjv.json`)).books
Insert cell
rst_json = (await d3.json(`https://jbbl.github.io/rst.json`)).books.filter(
(b) => b.nr >= 1 && b.nr <= 66
)
Insert cell
Insert cell
Insert cell
kjv_index = d3.json("https://jbbl.github.io/kjv/index.json")
Insert cell
Insert cell
st = d3.json(
"https://raw.githubusercontent.com/novchurch/today/main/_data/rst.json"
)
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more