Skip to content

tools for content editable elements. Inserting html, removing html, position caret, etc...

Notifications You must be signed in to change notification settings

svnm/content-edit

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

content-edit

npm version

tools for content editable elements. Inserting html, removing html, position caret, etc...

Thanks to tim down and his rangy module as most of the code is based on his work.

var contentEdit = require('content-edit');

var el = document.getElementById("content");
contentEdit.placeCaretAtStart(el);

Development

make sure you have babel installed globally to compile the src directory to the lib directory.

npm install --global babel

npm run build

Running Tests server side

modify test.js for any tests

npm install
npm test

Running Tests client side

modify test.js for any tests

npm install

make sure you have webpack installed globally

npm install webpack -g

compile test.js to a bundle with webpack

webpack ./test/test.js ./test/test-bundle.js

open test.html to view the tests in the browser

License

MIT

About

tools for content editable elements. Inserting html, removing html, position caret, etc...

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published