Home

MinimalComps2 is a single-file, drop-in JavaScript/HTML library allowing you to create a quick user interface for experiments or quick ideas.

The aim is for very concise, compact syntax. You can usually create a component, position it, configure it and create and event handler in a single line of code. Get them here:

Here’s what they look like. This is a live demo. Click around!

source for the above demo.

The Library

https://github.com/bit101/minimalcomps2

Browser Support

Tested pretty thoroughly on Chrome and Firefox on Linux and Mac. Somewhat less on Safari, and on Edge on Windows.

MinimalComps2 were not built with mobile browsers in mind. By default, they are too small to be usable. You can individually set the size of each component to be larger and more readable, and the touch events are pretty much working right now, but at any rate, it’s not going to be an ideal experience. They are made for rapid prototyping on a computer, and possibly releasing experiments or proof-of-concept apps on the web. Beyond basic functionality, there will not be much attention put on optimizing the components for mobile use.

History

The original MinimalComps was created (by myself) for Flash and ActionScript 3.0 back in 2008. It became a pretty popular way of creating a quick user interface for conceptual Flash pieces. After the demise of Flash, I attempted several abortive attempts to recreated the library in HTML/CSS/JavaScript. And at least a couple of attempts to do it in HTML Canvas and JavaScript. The more recent advances in JS/ES, as well as Web Components and the Shadow DOM have made this a lot easier and cleaner and I finally feel like this iteration is a worthy successor to the original.