summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJules Laplace <julescarbon@gmail.com>2021-08-16 16:28:11 +0200
committerJules Laplace <julescarbon@gmail.com>2021-08-16 16:28:11 +0200
commit6f29c59991925e8685a1911ce1b37c6097d7c517 (patch)
treee1a9fb1d45ec7e1115bf3123fca53b9ec9207c9e
parentbf563861320cf207bb2d788f50b327e4eb37016a (diff)
dense
-rw-r--r--src/index.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/index.js b/src/index.js
index 6cc83e4..39b3c7d 100644
--- a/src/index.js
+++ b/src/index.js
@@ -28,8 +28,8 @@ async function main() {
source: choice(trees[value]),
target: index,
});
- // don't link to the root node more than once!
- if (trees[value][0]) {
+ // option: don't link to the root node more than once
+ if (window.location.hash === "#dense" && trees[value][0]) {
trees[value].push(index);
} else {
trees[value] = [index];