ezmodel
TypeScript icon, indicating that this package has built-in type declarations

0.8.14 • Public • Published

ezmodel

Introduction

Overview

ezmodel simplifies web application state management. It provides a clear API for both local and global states, making your code cleaner and more maintainable.

Getting Started

Installation

Using npm

npm i ezmodel

Using yarn

yarn add ezmodel

Quick Start Guide

Wrap components with view(), define states with model() and using effect() to detect model change.

import { model, effect } from "ezmodel";
import { view } from "ezmodel/react";

const counter = model({ count: 0 });

effect(() => {
  console.log("count", counter.count);
});

const App = view(() => (
  <button onClick={() => counter.count++}>{counter.count}</button>
));

Features

  • Ease of Use: Straightforward setup.
  • Reactivity: Seamless state-to-UI binding.
  • Performance: Optimized for efficiency.

Learn More

License

This project is licensed under the MIT License - see the LICENSE file for details.

Community Support

For questions, discussions, or contributions, please join our community:

  • GitHub Issues: For reporting bugs or requesting new features, please use GitHub Issues.
  • Discussions: Join the conversation and ask questions in GitHub Discussions.
  • Contribute: Contributions are welcome! If you're interested in contributing, please read our CONTRIBUTING guide for more information on how to get started.

Stay connected and help improve ezmodel by sharing your feedback and ideas with the community!

Package Sidebar

Install

npm i ezmodel

Weekly Downloads

0

Version

0.8.14

License

MIT

Unpacked Size

332 kB

Total Files

115

Last publish

Collaborators

  • linq2js