vueactive

v0.15.0
React bindings for @vue/reactivity.

vueactive

npm version gzip size

React bindings for @vue/reactivity.

Installation

yarn add vueactive @vue/runtime-core

Examples

Counter

import React, { useState } from "react";
import { ref } from "@vue/reactivity";
import { component, useConstant } from "vueactive";

const { Fragment } = component;

const Counter = () => {
  return useConstant(() => {
    const count$ = ref(0);

    return (
      <>
        <button onClick={() => count$.value--}>-</button>
        <Fragment>{count$}</Fragment>
        <button onClick={() => count$.value++}>+</button>
      </>
    );
  });
};

export default Counter;

TodoMVC

npm i vueactive

Metadata

  • MIT
  • Whatever
  • Jas Chen
  • released 9/7/2021

Downloads

Maintainers