0.5.13 • Published 2 years ago

elevate-editor v0.5.13

Weekly downloads
175
License
-
Repository
-
Last release
2 years ago

Elevate Editor

Elevate Editor is an open-source, pluggable tool which can be utilized for building custom webpages, email templates, and more.

Should I Use This?

We are still making frequent changes to the internals and the API that is exposed. Feel free to use this now, but be aware that breaking changes are still likely at this point.

Demo

Usage

yarn add elevate-editor
import React, { Component, Fragment } from "react";
import ReactDOM from "react-dom";
import Editor from "elevate-editor";
import ThemeProvider from "elevate-ui/ThemeProvider";
import Paper from "elevate-ui/Paper";

class App extends Component {
  editor;

  render() {
    return (
      <ThemeProvider>
        <Paper>
          <Editor
            components={[]}
            content={[
              {
                type: "Row",
                attrs: {
                  disableDelete: true,
                  height: "600px",
                },
              },
            ]}
            innerRef={(editor) => {
              this.editor = editor;
            }}
            UPLOADCARE_API_KEY="demopublickey"
          />
          <button
            onClick={() => {
              console.log(this.editor.exportHTML());
            }}
          >
            Export HTML
          </button>
          <button
            onClick={() => {
              console.log(this.editor.exportJSON());
            }}
          >
            Export JSON
          </button>
        </Paper>
      </ThemeProvider>
    );
  }
}

const rootElement = document.getElementById("root");
ReactDOM.render(<App />, rootElement);

(above example running in codesandbox.io)

0.5.10

2 years ago

0.5.11

2 years ago

0.5.12

2 years ago

0.5.13

2 years ago

0.5.8

2 years ago

0.5.9

2 years ago

0.5.7

2 years ago

0.5.4

2 years ago

0.5.6

2 years ago

0.5.5

2 years ago

0.5.3

4 years ago

0.5.1

4 years ago

0.5.0

4 years ago

0.4.0

5 years ago

0.3.9

5 years ago

0.3.8

5 years ago

0.3.7

5 years ago

0.3.6

5 years ago

0.3.5

5 years ago

0.3.4

5 years ago

0.3.3

5 years ago

0.3.2

5 years ago

0.3.1

5 years ago

0.3.0

5 years ago

0.2.0

5 years ago

0.1.1

5 years ago

0.1.0

5 years ago

0.0.15

5 years ago

0.0.14

5 years ago

0.0.13

5 years ago

0.0.12

5 years ago

0.0.11

6 years ago

0.0.6-rc

6 years ago

0.0.10

6 years ago

0.0.8

6 years ago

0.0.7

6 years ago

0.0.6

6 years ago

0.0.5

6 years ago

0.0.4

6 years ago

0.0.3

6 years ago

0.0.2

6 years ago

0.0.1

6 years ago