mirror of
https://github.com/Noratrieb/my-binary-is-thicc-af.git
synced 2026-01-16 04:35:06 +01:00
initial commit
This commit is contained in:
commit
321af3e846
11 changed files with 1183 additions and 0 deletions
22
client/main.js
Normal file
22
client/main.js
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
import './style.css'
|
||||
import FoamTree from '@carrotsearch/foamtree';
|
||||
import groups from './groups.json'
|
||||
|
||||
const appElem = document.getElementById('app');
|
||||
console.log(appElem)
|
||||
const foamtree = new FoamTree({
|
||||
id: "app",
|
||||
layout: 'squarified',
|
||||
stacking: 'flattened',
|
||||
dataObject: {
|
||||
groups
|
||||
},
|
||||
});
|
||||
|
||||
window.addEventListener("resize", (() => {
|
||||
let timeout;
|
||||
return () => {
|
||||
window.clearTimeout(timeout);
|
||||
timeout = window.setTimeout(foamtree.resize, 300);
|
||||
};
|
||||
})());
|
||||
Loading…
Add table
Add a link
Reference in a new issue