{"name":"selection-range","description":"get or set the selction range, or cursor position, for contenteditable","version":"1.0.0","keywords":[],"dependencies":{"dom-iterator":"0.3.0"},"component":{"scripts":{"selection-range/index.js":"index.js"}},"license":"MIT","main":"index.js","repository":{"type":"git","url":"https://github.com/bmcmahen/selection-range.git"},"bugs":{"url":"https://github.com/bmcmahen/selection-range/issues"},"homepage":"https://github.com/bmcmahen/selection-range","_id":"selection-range@1.0.0","dist":{"shasum":"14cd8736eaba48679e557b70c2c5b538f9fe3941","tarball":"http://registry-npm.ywwl.com/selection-range/download/selection-range-1.0.0.tgz","integrity":"sha512-dDspNQ+b02uBKfS6J1pxDvmc7a+tey888BES2wr6AXk4CbYhH492UmHCjY/CkiURWws35ffZ55rvN9J1JOC73w==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCwUhRHIcQlH+IGM2SFe7y0/PVeIe2raAnL3Z0pPzpy3gIhAJxUux64EHkKaqNrxgUQPrCMpvZkue+uM8v4Kzu+Ixra"}],"size":2834,"noattachment":false,"key":"/selection-range/-/selection-range-1.0.0.tgz"},"_from":".","_npmVersion":"1.4.3","_npmUser":{"name":"bmcmahen","email":"ben.mcmahen@gmail.com"},"maintainers":[{"name":"tootallnate","email":"nathan@tootallnate.net"},{"name":"bmcmahen","email":"ben.mcmahen@gmail.com"}],"directories":{},"readme":"\n# selection-range\n\n  Get or set the selection range, or cursor position. Useful for saving and restoring selections when your are programatically changing the dom.\n\n## Installation\n\n    $ component install bmcmahen/selection-range\n    $ npm install selection-range\n\n## Usage\n\n```javascript\nvar select = require('selection-range');\nselect(el, { start: 5, end: 25 }); // select range of el from 5 - 25\nselect(el, { start: 5 }); // set the cursor at 5\nvar pos = select(el); // get range of selection\n// pos.start = start index\n// pos.end = end index\n// pos.atStart = boolean. true if cursor should appear at start of el\n// pos = undefined if no cursor\nselect(el, pos);\n```\n\n## Tests\n\n```\nnpm install component-test -g\ncomponent test browser\n```\n\n## License\n\n  MIT\n","publish_time":1408137468246,"_cnpm_publish_time":1408137468246,"dist-tags":{"latest":"1.1.0"}}