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

0.1.13 • Public • Published

Editure for React

The React component for Editure.

Using the Component

A quick demo:

import Editure from 'editure-react';
 
class MyComponent extends React.Component {
  constructor(props) {
    super(props);
    this.state = { value: [] };
  }
 
  handleChange = value => {
    this.setState({ value });
  };
 
  render() {
    return <Editure value={this.state.value} onChange={this.handleChange} />;
  }
}

Or, if you prefer Hooks:

import Editure from 'editure-react';
 
function MyComponent() {
  const [value, setValue] = useState([]);
  return <Editure value={value} onChange={setValue} />;
}

Readme

Keywords

none

Package Sidebar

Install

npm i editure-react

Weekly Downloads

24

Version

0.1.13

License

MIT

Unpacked Size

37.6 kB

Total Files

20

Last publish

Collaborators

  • powerformarc
  • tomwenthey
  • pftom