Skip to content
forked from anthonyshort/deku

A simple library for creating UI components using virtual DOM.

Notifications You must be signed in to change notification settings

yoshuawuyts/deku

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Deku

Join the chat at https://gitter.im/segmentio/deku version Circle CI

A simple library for creating UI components using virtual DOM.

npm install deku

Read the documentation on the wiki →

Features

  • It's small at roughly 8kb.
  • Supports npm, Duo, and Bower. Learn More →
  • It only supports IE10+ and better browsers. Learn More →
  • Server-side rendering.
  • Easily test components.
  • Handles all event delegation for you without virtual events.
  • Batched and optimized updates using requestAnimationFrame.

Example

var {component,dom} = require('deku');

var Button = component({
  onClick() {
    this.setState({ clicked: true });
  },
  render(props, state) {
    return dom('button', { onClick: this.onClick }, [props.text]);
  }
});

var scene = Button.render(document.body, {
  text: 'Click Me!'
});

scene.setProps({
  text: 'Seriously, click me.'
});

About

A simple library for creating UI components using virtual DOM.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 93.0%
  • HTML 6.2%
  • Other 0.8%