Skip to content

Instantly share code, notes, and snippets.

@sandrosc
Created May 14, 2017 21:52
Show Gist options
  • Save sandrosc/d860cf2db4660c6151a8dee2ab0bef9f to your computer and use it in GitHub Desktop.
Save sandrosc/d860cf2db4660c6151a8dee2ab0bef9f to your computer and use it in GitHub Desktop.
Medium Editor section vs div
p to reproduce just delete all the text and hit back again (so the p-tag gets deleted)
div.wrapper
div.editable
p default div
section.editable
p default section
var editor = new MediumEditor('.editable', {
// options go here
});
console.log(editor)
<script src="https://cdnjs.cloudflare.com/ajax/libs/medium-editor/5.23.0/js/medium-editor.min.js"></script>
.wrapper {
display: flex;
justify-content: space-around;
}
.wrapper>* {
width: 300px;
height: 300px;
border: solid 1px black;
}
<link href="https://cdnjs.cloudflare.com/ajax/libs/medium-editor/5.23.0/css/medium-editor.min.css" rel="stylesheet" />
<link href="https://cdnjs.cloudflare.com/ajax/libs/medium-editor/5.23.0/css/themes/default.min.css" rel="stylesheet" />
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment