npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

reaxes

v1.4.0

Published

A distributed and reactive programming style, which allows you to write the core logic of the app, can run on every view framework.

Readme

What's This

reaxes的设计哲学是:应用的逻辑应该与其他模块解耦,特别是视图用户输入

  • 此库可以让你以响应式编程思维来构建你的应用的核心逻辑,无论是web前端还是nodejs,只要宿主环境支持Proxy即可以运行.
  • 将复杂的业务逻辑从视图组件中抽离, 数据和逻辑将在应用的任何地方可用,而不再是组件和hooks中了.
  • 跨视图同构你的应用,一套逻辑,可以在react,vue中轻易通用而不用修改任何组件代码.甚至native app , web , 小程序中都可以通用,只需要根据宿主环境做些判断.

注意:1.x.x大版本并不稳定,每个中间版本号增加都意味着api可能会修改或删除

Installation

$ npm i -S reaxes

Documents

https://kane-7.gitbook.io/reaxes-document

Playground

Using reaxes to build core logic of your app

// reaxels/counter.ts
import { createReaxable , obsReaction } from 'reaxes';

export const reaxel_Counter = reaxel(() => {
	//create a reactive store , so you can subscribe changes when you need.
	const { store , setState , mutate } = createReaxable({
		count : 0,
	});
	
	return Object.assign(() => {
		return {
			get count(){
				return store.count;
			} ,
			setCount( count: number ){
				setState({ count });
			} ,
		};
	} , {
		store ,
		setState ,
		mutate ,
	});
});

Using with vallina JS

// when count changed, refresh DOM
import { reaxel_Counter } from './reaxels/counter';
import { obsReaction } from 'reaxes';

function render(){
   const { count , setCount } = reaxel_Counter();
   
   const div = document.createElement('div');
   div.onclick = () => setCount(count + 1);
   div.innerText = count;
   return div;
}

//listen store.count , once it changes,render() will be re-runed automatically
obsReaction(
   ( first , dispose ) => {
      document.write(render());
      if(first){
         console.log('div element mounted');
      }
   } ,
   //place all observable props here
   () => [ reaxel_Counter().count ]
);

using with React

// there is no need to use obsReaction for every component
// because reaxper will do this automaticlly
// all you need is just to wrap you components with reaxper();
import { reaxper } from 'reaxes-react';
import { reaxel_Counter } from './reaxels/counter';

// functional component
export const Count = reaxper(() => {
   const {count,setCount} = reaxel_Counter();
   
   return <div onClick = { () => setCount(count+1) }>
      count:{ count }
   </div>;
});

// or use class component
import { Component } from 'react';

@reaxper
class CountComponent extends Component {
   
   render(){
      const {count,setCount} = reaxel_Counter();
      
      return <div onClick = { () => setCount(count+1) }>
         count:{ count }
      </div>;
   }
}

using with Vue2

<template>
   <div @click="setCount()">
      {{ count }}
   </div>
</template>
<script>
   import { reaxel_Counter } from './reaxels/counter';
   
   export default {
      status(){
         const {count} = reaxel_Counter();
         return { count };
      },
      methods:{
         setCount(){
            const {count,setCount} = reaxel_Counter();
            setCount(count+1);
         }
      }
   }
</script>