Skip to content

Demo how to do simple state update (and trigger re-render) with varies of SPA framework

Notifications You must be signed in to change notification settings

beenotung/spa-state-demo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SPA State Management Demo

This repo demo how to do simple state update (and trigger re-render) with varies of SPA framework.

The example used is simply getting two numbers from input, then display the sum.

Comparison

Framework / Tool # Significant Expression* Required LoC* Size** of node_modules Size** of Built File***
Svelte 7 19 22M 17.4K
Angular 7 38 242M 155.8K
Vue 10 43 101M 49.3K
Stencil 11 48 16M 13.7K
React 14 32 205M 144.6K
Vanilla 10 16 0B 0.3K

*: the lower, the better

**: file size are in unit of MB or KB (powers of 1024), measured with du -sh --apparent-size node_modules

***: excluded *.map files

LoC: line of code

Remark: the vanilla html file is minified with minify

Svelte

Angular

Vue

Stencil

React

Vanilla

About

Demo how to do simple state update (and trigger re-render) with varies of SPA framework

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published