Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/wangzuo/react-medium-editor
React wrapper for medium-editor
https://github.com/wangzuo/react-medium-editor
Last synced: 6 days ago
JSON representation
React wrapper for medium-editor
- Host: GitHub
- URL: https://github.com/wangzuo/react-medium-editor
- Owner: wangzuo
- License: mit
- Created: 2015-05-21T13:01:19.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2023-05-29T05:36:30.000Z (over 1 year ago)
- Last Synced: 2024-11-30T22:02:44.616Z (13 days ago)
- Language: JavaScript
- Homepage: https://wangzuo.github.io/react-medium-editor
- Size: 1000 KB
- Stars: 504
- Watchers: 10
- Forks: 93
- Open Issues: 26
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-react-components-all - react-medium-editor - React wrapper for medium-editor. (Uncategorized / Uncategorized)
- awesome-react-components - react-medium-editor - medium-editor wrapper. (UI Components / Form Components)
- awesome-react - react-medium-editor - medium-editor wrapper. ![](https://img.shields.io/github/stars/wangzuo/react-medium-editor.svg?style=social&label=Star) (UI Components / Form Components)
- awesome-list - react-medium-editor - React wrapper for medium-editor. (Demos / Form Components)
- awesome-react-components - react-medium-editor - medium-editor wrapper. (UI Components / Form Components)
- awesome-react-components - react-medium-editor - React wrapper for medium-editor. (UI Components / Form Components)
- awesome-react-components - react-medium-editor - medium-editor wrapper. (UI Components / Form Components)
- fucking-awesome-react-components - react-medium-editor - medium-editor wrapper. (UI Components / Form Components)
README
# react-medium-editor
React wrapper for [medium-editor](https://github.com/daviferreira/medium-editor)
### Demo
[http://wangzuo.github.io/react-medium-editor](http://wangzuo.github.io/react-medium-editor)
### Installation
```sh
npm install react-medium-editor --save
```### Usage
```javascript
// load theme styles with webpack
require('medium-editor/dist/css/medium-editor.css');
require('medium-editor/dist/css/themes/default.css');// ES module
import Editor from 'react-medium-editor';// CommonJS enviroment
// var Editor = require('react-medium-editor').default;var App = React.createClass({
getInitialState() {
return { text: 'Fusce dapibus, tellus ac cursus commodo' };
},render() {
return (
react-medium-editor
Html content
{this.state.text}
Editor #1 (<pre> tag)
Editor #2
);
},handleChange(text, medium) {
this.setState({ text: text });
}
});
```### License
MIT