wirwox
v0.0.3
Published
...
Downloads
8
Maintainers
Readme
wirwox
Javascript UI Library
Wirwox is a experimental 'proof of concept' Javascript UI library for building user interfaces. It's small and lightweight - 13kb minified.
The purpose with this library was too see how much of React's component API I could re-use in a new library without replicating React itself.
This is not an attempt to reinvent the wheel. We already have Angular, React and other great libraries such as Inferno, Kivi and Cito.
What is the idea behind this?
Wirwox is a result of my research on the virtual DOM concept. It's far from complete, but it works and it's 100% React compatible in a small size core. You can do almost the exact things when it comes to the component API.
How to use
From React, Wirwox uses a few of the same functions.
render
unmount
- (React:unmountcomponentatnode
)createClass
createElement
Component
findDOMNode
PropTypes
You use this in the same way. To create virtual elements, you can do:
Wirwox.createElement('div', container);
Wirwox.createElement(function(){}, container); // functional or component
To unmount, you can do:
Wirwox.unmount(container);
Things to fix
There is a lot of things to fix. When I build this, I took the best ideas from all Javascript libraries out here, and merged it into Wirwox.
Note! Be aware that things that isn't fixed or implemented yet, will probably not be it either.
Here is a short list for things that need to be fixed with a reference to other Vdom implementations:
- proper children diffing algorithm - Inferno, Kivi and Cito
- proper diffing of attributes, properties, and style - Kivi
- support for string text nodes - Cito, Inferno, Kivi
- RenderToString - React
- Add support for the new features added in React 15.x
- Improved ref support for components
- Lifecycle hooks for stateless components - Inferno
- Splitting into packages - React, Inferno
- JSX (React JSX plugin may work)
- Event system - React
- Bug fixes
- Major improvements
Note! First priority is to move the cache solution from the DOM node itself to the virtual DOM object to gain better performance.