VNDB fork of mithril.js
Find a file
Leo Horie ef8b7c680c Merge pull request #1524 from barneycarroll/patch-5
Use HTML / JSX as appropriate instead of 'markup'
2017-01-10 18:58:05 -05:00
api #1520 ospec: report duplicate test names 2017-01-08 13:05:27 -05:00
bundler #1520 ospec: report duplicate test names 2017-01-08 13:05:27 -05:00
docs Merge pull request #1524 from barneycarroll/patch-5 2017-01-10 18:58:05 -05:00
examples use animation best practices in dbmon 2016-12-02 20:44:03 -05:00
module lint 2016-09-23 22:49:20 -04:00
ospec [ospec] fix nextTickish() 2017-01-10 14:59:09 +01:00
promise #1520 ospec: report duplicate test names 2017-01-08 13:05:27 -05:00
querystring Replace x instanceof Array with Array.isArray(x) 2016-11-24 09:21:27 +00:00
render Merge pull request #1516 from tivac/issues/1014 2017-01-07 15:19:16 -05:00
request #1520 ospec: report duplicate test names 2017-01-08 13:05:27 -05:00
router add support for route state #1480 2016-12-17 21:50:04 -05:00
stream Make it work in a browser 2016-12-21 10:02:21 +11:00
test-utils lint and highlight jsx 2017-01-08 19:30:23 -05:00
tests add integration test 2016-12-04 23:36:38 -05:00
util simplify streams, lint docs 2016-11-15 23:13:38 -05:00
.deploy.enc Set up repo for travis commits (#1210) 2016-08-04 09:58:28 -07:00
.editorconfig Add editorconfig, resolve differences 2016-06-18 03:22:12 -04:00
.eslintignore lint 2016-11-15 23:20:22 -05:00
.eslintrc.js bypass route resolution algorithm on non-routed redraws 2016-12-05 11:23:25 -05:00
.gitattributes change line endings, step 1 2016-10-26 15:23:19 -04:00
.gitignore remove ambiguity in oncreate hook docs 2016-11-01 23:30:29 -04:00
.npmignore Revert #1449 2016-12-16 10:34:12 +00:00
.travis.yml Travis should lint & bundle before every build (#1441) 2016-11-30 11:51:10 -08:00
browser.js unbreak bundler 2016-08-03 00:01:17 -04:00
hyperscript.js improved bundler, handle width/height atts 2016-09-23 10:31:33 -04:00
index.js Expose Vnode as m.vnode (#1487) 2016-12-20 21:19:16 -08:00
mithril.js Bundled output for commit 4fc9368a30 [skip ci] 2017-01-07 20:20:45 +00:00
mithril.min.js Bundled output for commit 4fc9368a30 [skip ci] 2017-01-07 20:20:45 +00:00
mount.js fix #1404 2016-12-01 01:45:07 -05:00
package.json rc7 2016-12-29 15:58:18 -05:00
README.md Bundled output for commit 4fc9368a30 [skip ci] 2017-01-07 20:20:45 +00:00
redraw.js fix #1404 2016-12-01 01:45:07 -05:00
render.js rename routeresolver methods to {onmatch,view} 2016-08-17 00:10:47 -04:00
request.js change m.request return value from stream to promise 2016-11-13 22:44:22 -05:00
route.js fix #1404 2016-12-01 01:45:07 -05:00
stream.js simplify streams, lint docs 2016-11-15 23:13:38 -05:00

Mithril.js - A framework for building brilliant applications

Installation | API | Examples | Changelog/Migration Guide

Note: This branch is the upcoming version 1.0. It's a rewrite from the ground up and it's not backwards compatible with Mithril 0.2.x. You can find preliminary documentation here and migration guide here

This rewrite aims to fix longstanding API design issues, significantly improve performance, and clean up the codebase.

Early Preview

You can install this via NPM using this command:

npm install mithril@rewrite

Examples run out of the box. Just open the HTML files.

Status

The code is fairly stable and I'm using it in production, but there may be bugs still lurking.

Some examples of usage can be found in the examples folder. ThreadItJS has the largest API surface coverage.

Partial documentation can be found in the /docs directory

Performance

Mithril's virtual DOM engine is around 500 lines of well organized code and it implements a modern search space reduction diff algorithm and a DOM recycling mechanism, which translate to top-of-class performance. See the dbmon implementation (for comparison, here are dbmon implementations for React v15.3.2, Angular v2.0.0-beta.17 and Vue 2. All implementations are naive (i.e. apples-to-apples, no optimizations)

Robustness

There are over 4000 assertions in the test suite, and tests cover even difficult-to-test things like location.href, element.innerHTML and XMLHttpRequest usage.

Modularity

Despite the huge improvements in performance and modularity, the new codebase is smaller than v0.2.x, currently clocking at 7.60 KB min+gzip

In addition, Mithril is now completely modular: you can import only the modules that you need and easily integrate 3rd party modules if you wish to use a different library for routing, ajax, and even rendering