Skip to content

2.0.0

Latest
Compare
Choose a tag to compare
@jorgebucaran jorgebucaran released this 26 Jul 19:55
2.0.0
6fa24d3

Hyperapp 2.0 brings a host of new features and improvements, empowering you to build more efficient and feature-rich web apps:

  • We're excited to introduce our new Tutorial, enhanced Examples, and comprehensive Reference.
  • New Features: Hyperapp 2.0 introduces several new features, including Effects, Subscriptions, and an enhanced Dispatch mechanism.
  • Explore the flowchart to gain a clearer insight into Hyperapp's workflow. 🔍

Features

  • h() and text(): The h() function creates virtual DOM nodes (VNodes) for defining views, while text() generates text content nodes for insertion.
  • Memoization: Hyperapp 2.0 offers a memoization feature through the memo() function to optimize rendering performance.
  • App Initialization: You can initialize your app by setting the initial state, running a list of effects, or directly invoking an action.
  • Mounting: Hyperapp 2.0 allows you to specify the DOM element where the virtual DOM will be mounted.
  • Effects: Effects in Hyperapp 2.0 provide a structured way to manage impure code, such as making API calls, handling animations, and more. Effects enhance the predictability and maintainability of your applications.
  • Subscriptions: Subscriptions simplify handling external events and resource management, ensuring safe, pure, and immutable interactions with the outside world.
    • Custom Subscriptions: Create custom subscriptions when official packages do not meet your app's requirements.
  • Dispatch: The dispatch function controls the core dispatching process, including executing actions, applying state transitions, and running effects.
    • Custom Dispatch: You can create custom dispatch initializers to customize and augment the dispatching process for debugging and telemetry.
  • Custom JSX Function: Although Hyperapp 2.0 does not natively support JSX, you can use a custom JSX function to enable JSX syntax.

Acknowledgements

An immense thank you to @zaceno, @okwolf, @icylace, @sergey-shpak, @SkaterDad, and @lukejacksonn. Your contributions have been invaluable. ❤️