Skip to content
This repository has been archived by the owner on Nov 22, 2018. It is now read-only.

Use morphdom #18

Merged
merged 42 commits into from
Jun 1, 2016
Merged

Use morphdom #18

merged 42 commits into from
Jun 1, 2016

Conversation

shawnbot
Copy link
Owner

@shawnbot shawnbot commented May 23, 2016

This started as an attempt at using virtual-dom, but then I came across morphdom and fell in love, so I used that instead. Most of the previously pending tests under incremental-dom have been fixed in this transition, with the notable exception of events (which are still undocumented, and obviously broken). There are also a bunch of new unit tests for the underlying code components, including a native DOM implementation of virtual-dom's "hyperscript" (h()) function.

In this PR:

  • Move the class and style transforms to h()
  • Cursory tests for element and attribute namespaces
  • Major reorganization of functions, refactoring
  • Linting with eslint
  • Figure out namespace awareness in morphdom: SVG / NS Support patrick-steele-idem/morphdom#34
  • Basic support for event listeners!
  • Proper tests for element namespaces (e.g., preserve <svg> inferred namespaceURI)
  • Proper tests for attribute namespaces (e.g., preserve xlink:href)
  • Consider just using hyperscript, pending an investigation into its namespace support
  • Add tests for <t-template>??

@shawnbot shawnbot self-assigned this May 23, 2016
@shawnbot
Copy link
Owner Author

Oh, and: the full JS build (including document-register-element) is now 4K smaller at 20K!

@shawnbot
Copy link
Owner Author

Another nice thing about using the h() signatures is that it will be much easier to either swap out morphdom later if need be, or even to offer the ability to add a compatibility layer with virtual-dom.

@shawnbot shawnbot mentioned this pull request May 28, 2016
@shawnbot shawnbot merged commit 84dd301 into master Jun 1, 2016
@shawnbot shawnbot deleted the morphdom branch June 1, 2016 03:51
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant