Skip to content

Releases: jorgebucaran/hyperapp

0.12.0

18 Aug 16:16
120cc5d
Compare
Choose a tag to compare

Logo

  • The logo creatively combines the letters h and a.
  • Its design shines in thumbnails with symmetric round corners and thicker lines for prominence.
  • A visual delight, now in a vibrant #00C8FF.

Hyperapp Logo

0.11.0

12 Aug 19:37
9fe4f0e
Compare
Choose a tag to compare

Version 0.11.0 brings comprehensive updates: new documentation, non-destructive rendering, container-based root, hydration enhancements, thunks, app events, a revamped component lifecycle architecture, POJO (plain old JavaScript object) state, 100% test coverage restoration, and several bug fixes.

Root & Hydration

  • The root now serves as a container, not a replaceable target, enabling non-destructive rendering.
  • Hydration improvements:
    • Checks if load returns the same root node, indicating non-hydration use, setting oldNode and element to null.
    • If nodes differ, assumes oldNode as a valid virtual node and element as a DOM node, leaving re-hydration to the patch function.
  • The update event triggers only for truthy new states, allowing false returns to cancel re-rendering.

App Events

  • Enforced use of a POJO as the application state; primitive types are no longer valid.
  • New event functions introduced:
    • load: Initializes and loads app resources.
    • render: Customizes the view function.
    • action: Logs or saves action data.
    • resolve: Modifies action behavior.
    • update: Inspects and validates state changes.

Lifecycle Events

  • Deferred oncreate and onupdate calls post-patch, maintaining correct order for nested elements.
  • onupdate now receives old data/attributes for prop change logic.
  • Ensured onremove is called when elements are replaced.
  • Removed oninsert in favor of oncreate.

Other

  • Removed rollup.config.js in favor of direct command line Uglify use.
  • Renamed mixin composition to presets.
  • Refactored thunks, removing built-in promise support for thunk composition.
  • Rewrote Code of Conduct based on the open code of conduct.

Acknowledgments

Thank you to everyone who contributed to this release: @Swizz, @lukejacksonn, @andyrj, @jamen, @zaceno, @fsodano, @tscholl2, @matejmazur, @jcubic, @dodekeract, and @madebyherzblut. See you next time! 👋

0.10.0

13 Jul 08:49
bb33eef
Compare
Choose a tag to compare

This release brings numerous changes and enhancements to Hyperapp. A big shoutout to everyone who contributed to making this release possible. See you next time! 👋

  • Launched Hyperapp's official landing page. Kudos to @lukejacksonn for the development. [Source].
  • Adopted the Contributor Covenant Code of Conduct.
  • Introduced DOM hydration support. Thanks to @andyrj and @ngryman for this feature aimed at preserving server-side rendered DOM nodes.
  • Implemented batch patches and render pipeline optimization using requestAnimationFrame (rAF).
    • New init event introduced for pre-first render actions.
    • The loaded event now triggers once after the first render.
  • Changed DOMContentLoaded handling:
    • Breaking change for scripts included in <head>. Use DOMContentLoaded listener or defer attribute in the script tag.
    • No changes needed for scripts at the bottom of <body>.
  • New lifecycle event oninsert introduced, firing post-oncreate when elements are in the DOM.
  • Added bundlesize tracking for bundle size changes.
  • Mixins can now include their own mixins, thanks to @jamen.
  • Enabled triggering events from outside app() calls, courtesy of @zaceno.
  • Added a new TweetBox example.
  • The router is now separate from core. Follow @hyperapp/router for updates and ongoing improvements.

0.9.2

04 Jun 08:55
af50edb
Compare
Choose a tag to compare
  • Resolved an issue where the onupdate handler was called even when undefined (#215).
  • Fixed input type=text selection reset, preventing cursor/selection from jumping to the end when the value attribute is state-bound (#224). See a working example here.
  • Updated Router.go to handle URLs with query strings effectively (#217).
  • Changed the behavior of onremove. If you use onremove, you must now manually remove the element from the DOM. This update enables the creation of slide-out transitions/animations. Special thanks to @zaceno for this contribution.

0.9.0

30 Apr 09:26
6e89231
Compare
Choose a tag to compare
  • @madebyherzblut fixed an issue where attributes were always converted to lowercase, impacting case-sensitive attributes like viewBox in most browsers.
  • Implemented a check to ensure data is set before invoking onremove, thanks @maraisr.
  • @zaceno added a test for scenarios where plain-string vnodes are removed.
  • Major documentation rewrite and addition of tutorials. A special shoutout to @lukejacksonn and @selfup for their redaction tips.
  • Updated event naming conventions: no more camelCase. Breaking Change. Examples: onClickonclick, onCreateoncreate.
  • Normalized actions/events signatures to (state, actions, data, emit) (#190).
  • @ngryman enhanced the h function, optimizing its performance (#187).
  • Introduced benchmark and tracing scripts for h by @ngryman (#186).

0.8.1

15 Apr 02:32
7284023
Compare
Choose a tag to compare
  • Renamed model to state for clarity (#173).
  • Replaced subscriptions and hooks with a new events system for more streamlined application interaction (#174).
    app({
      events: {
        loaded: (state, actions, emit) => {/* ... */},
        action: (state, actions, data, emit) => {/* ... */},
        update: (state, actions, data, emit) => {/* ... */},
        render: (state, actions, data, emit) => {/* ... */},
        route:  (state, actions, data, emit) => {/* ... */}
      }
    })
  • Default mount to document.body for applications without a specified root (#140).
  • Lifecycle events are no longer deferred, enabling immediate response to state changes (#171).
  • Event handlers set as properties, not attributes, for improved performance (#175).
  • Added keys in elements for better management in lists, similar to React's approach (#172, #141, #117).
  • Introduced the emit(eventName, eventData) function for creating custom events (#177, #178).

Acknowledgments

Special thanks to @zaceno for the introduction of keys. Appreciation also goes to @pedroborges, @lukejacksonn, @selfup, @ngryman, @dodekeract, and @leeoniya for their contributions to this release.

0.4.0

15 Feb 06:39
41bb9de
Compare
Choose a tag to compare
  • Hyperapp on cdnjs (#10613). 🎉
  • Removed Hyperx Dependency:
    • Opting out of bundling Hyperx with Hyperapp.
    • Results in a 1/3 smaller bundle for CDN users.
    • Hyperapp now operates as a dependency-free module.
    • Easier integration with hyperxify.
  • Shift to ES6 (#89):
    • Simplifies setups for webpack/rollup users.
    • Facilitates treeshaking for unused module removal (treeshaking guide).
    • Implements jsnext:main and module for modern bundler compatibility.
    • UMD bundle distribution, with pkg.main → dist/hyperapp.js for Node.js.
  • Router update: now accepts a render(view) function and options.
  • New release and prepublish npm scripts for maintenance.
  • Improved Documentation: Detailed guides for browserify, webpack, and rollup.
  • Uglify Optimizations for a smaller bundle.

Acknowledgements

Thank you to all who have supported Hyperapp's journey @rbiggs, @tzellman, @danigb, @selfup, @terkelg, and others. Your contributions are greatly appreciated! 👋

0.1.0

12 Feb 11:48
6afceae
Compare
Choose a tag to compare
  • Added support for function nodes in JSX and h, enabling child components like <MyComponent props=...>children</MyComponent>. See this example.
  • Now distributing a single minified hyperapp.js on CDNs.
  • Improved documentation consistency, thanks to @rbiggs.
  • Standardized editor styles for contributors, courtesy of @tzellman.
  • Achieved 100% coverage.

0.0.13

09 Feb 12:48
49815f5
Compare
Choose a tag to compare
  • New tests added (#60).
  • Documentation improved for clarity.
  • API consistency improved (#53).

0.0.12

07 Feb 16:49
88d6204
Compare
Choose a tag to compare

Hyperapp now supports both Hyperx (tagged template literals) and JSX. Choose the appropriate distribution for your needs.

<script src="https://unpkg.com/[email protected]/dist/hyperapp.hx.js"></script>  <!-- Hyperx -->

<script src="https://unpkg.com/[email protected]/dist/hyperapp.js"></script>