wileam / binding-demo

A 2 way binding demo from scratch by vanilla js, without 3rd party libs.

Home Page:http://wileam.com/binding-demo/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Demo for 2 way data binding

Install

npm install

Run

npm start

Usage

  • Dom --> Data

Change the value of input in browser and see how data changes on console.

  • Data --> Dom

On the console, get data and change it's value, DOM will change accordingly.

data.value = 'hello world'

Requirement

  1. DOM --> Data

listener

data.value = input.value

  1. Data --> DOM

listener

input.value = data.value

  1. Data --> Multiple DOM &

  2. Data --> TodoList

div --> ul > li

object --> array of object

About

A 2 way binding demo from scratch by vanilla js, without 3rd party libs.

http://wileam.com/binding-demo/


Languages

Language:JavaScript 74.4%Language:HTML 25.6%