Skip to content

Instantly share code, notes, and snippets.

@P1xt
Created March 13, 2017 18:17
Show Gist options
  • Save P1xt/5bc72ce969f5a590a9c815af98ffa3df to your computer and use it in GitHub Desktop.
Save P1xt/5bc72ce969f5a590a9c815af98ffa3df to your computer and use it in GitHub Desktop.
Angular 2 - two way data binding for markdown previewer
<div id="pre-marked" class="preview">
<textarea [(ngModel)]="input" name="text" class="text" ></textarea>
</div>
<div></div>
<div id="marked" class="preview">
<div innerHtml={{input|mark}} name="text-marked" class="text" ></div>
</div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment