- Zero dependencies: wow, this is really good for a js package.
- Documentation: nice, clear and with examples
- Transparent builds: this should be a standard
I wish more js packages were like yours
Can you explain what "Transparent builds" means in this context?
From my understanding after a quick search, it is the standard. If any package requires me to figure out a manual build process after installing it, to get it to work, I simply do not use it.
Once it's available in even one browser not behind a flag, sure, but while it's still entirely undocumented and only available to people who both use Chrome Canary and know to go turn on a specific flag?
https://dockview.dev/docs/core/panels/rendering
Options exist for multiple cases:
1. Where you never want the elements DOM position to move (`always` rendering mode) and the HTMLElement is simply hidden (display: none) when not visible. 2. Where you only want the DOM element to exist when the panel is visible (`onlyWhenVisible` mode)
In the case of React the React Tree is always maintained in either mode.
Also is there a version without window chrome, just panes?
Technically speaking, I've long wondered about mount/unmount of components as panels are dragged about and their visibility changed. Sometimes it's more costly to mount/unmount than to display:none.
Second, you have basically a declarative structure for these panels, are there plans to expose a Vite plugin for example that could export saved TS layouts, where functions (ie: TS imports) map to the panel contents? (trying to think outside of JSX and more vanilla TS)
Fantastic work!
https://dockview.dev/docs/core/panels/rendering
There are options to maintain the panels content within the DOM at all times (using an approach like you mentioned with display: none) and options to remove content from the DOM.
In terms of vanilla TS the library is almost entire written in vanilla TS with small wrapper libraries for Vue and React.
In theory wrappers could be written for other frameworks such as Angular (which is something I would like to get done this year)
Loading and saving state is supported though
https://dockview.dev/docs/core/state/save
Let me know if that answers the question
I really enjoyed that project back in the day, but unfortunately support completely stopped (it had some folks take over, but I didn't see a real feasible upgrade path despite their passionate work on updating it).
This looks great! I'd be interested in giving it a try.
Orginally yes it was inspired by some of the other layout managers, include golden layout. The main goal here was to have zero depenedencies and to be written in Vanilla TypeScript with wrapper libraries for frameworks such as Vue and React.
Any feedback is appreicated, the website demo shows most of the current capabilities and there are many more planned in the Issues list.
The video looks awesome, but I couldn’t get the demo to work using an iPad, so I assume mobile isn’t supported fully? I’d use it for my personal dashboard and for organizing llama.cpp chats if I could.
Is there a way to add gaps between the elements so it looks like a dashboard rather than panel?
Is anyone aware of any sort of similar sort of zero-dep vanilla libraries for common desktop controls beyond what HTML offers? E.g. menus etc?
The only reason I in the end went with FlexLayout (https://github.com/caplin/FlexLayout) for a recent project was lack of support for predefined/restricted dimensions, - which was since added in a very good way - and that I really liked how FL handles side panels, with vertical tabs, and their predefined behavior.
Looking very much forward to using Dockview in one of the next projects.