Sign Up for Free

RunKit +

Try any Node.js package right in your browser

This is a playground to test code. It runs a full Node.js environment and already has all of npm’s 400,000 packages pre-installed, including ng2-meditor with all npm packages installed. Try it out:

var ng2Meditor = require("ng2-meditor")

This service is provided by RunKit and is not affiliated with npm, Inc or the package authors.

ng2-meditor v1.0.1

Medium Editor for Angular2

ng2-medium-editor

Medium Editor component for Angular 2 (https://yabwe.github.io/medium-editor/)

Install

npm install --save ng2-meditor

How to use

Include Medium Editor script and style in index.html. Read from https://yabwe.github.io/medium-editor/

In your component:

...
import { MediumEditorComponent } from 'ng2-meditor';

@Component({
    selector: 'my-app',
    directives: [ MediumEditorComponent ],
    template: `
    <form ngForm="form">
        <medium-editor
            name="content"
            [(ngModel)]="content"
            placeholder="Replace your placeholder"></medium-editor>
    </form>
    `
})

export class AppComponent {
    content = '<h1>This is example!</h1>';
}

...
RunKit is a free, in-browser JavaScript dev environment for prototyping Node.js code, with every npm package installed. Sign up to share your code.
Sign Up for Free