@hackforplay/react-ast-mutator-components
React components to mutate Babel AST.
Last updated 4 months ago by teramotodaiki .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @hackforplay/react-ast-mutator-components 
SYNC missed versions from official npm registry.

React AST Mutator Components

Build Status

Install

  • npm i -S @hackforplay/react-ast-mutator-components

React Project

import { RootComponent } from '@hackforplay/react-ast-mutator-components';
import { React, useState } from 'react';

export function MyComponent() {
  const [code, setCode] = useState('let a = 1');

  return <RootComponent code={code} onChange={value => setCode(value)} />;
}

Othe Framework

import { render } from '@hackforplay/react-ast-mutator-components';

let code = 'let a = 1';

update();

function update() {
  render(
    {
      code,
      onChange(value) {
        code = value;
        update();
      }
    },
    document.body
  );
}

Current Tags

  • 1.3.0                                ...           latest (4 months ago)

19 Versions

  • 1.3.0                                ...           4 months ago
  • 1.2.8                                ...           a year ago
  • 1.2.7                                ...           a year ago
  • 1.2.6                                ...           a year ago
  • 1.2.5                                ...           a year ago
  • 1.2.4                                ...           a year ago
  • 1.2.3                                ...           a year ago
  • 1.2.2                                ...           a year ago
  • 1.2.1                                ...           a year ago
  • 1.2.0                                ...           a year ago
  • 1.1.6                                ...           a year ago
  • 1.1.5                                ...           a year ago
  • 1.1.4                                ...           a year ago
  • 1.1.3                                ...           a year ago
  • 1.1.2                                ...           a year ago
  • 1.1.1                                ...           a year ago
  • 1.1.0                                ...           a year ago
  • 1.0.1                                ...           a year ago
  • 1.0.0                                ...           a year ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (13)
Dev Dependencies (12)
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |