{"name":"draft-js-prism","version":"1.0.3","description":"Code highlighting for DraftJS","main":"./lib/index.js","scripts":{"test":"mocha \"./lib/__tests__/*.js\" --bail --reporter=list","build":"browserify -t [ babelify --presets [ es2015 react ] ] ./demo/main.js > ./demo/dist.js; cp ./node_modules/prismjs/themes/prism.css ./demo/prism.css; cp ./node_modules/draft-js/dist/Draft.css ./demo/draft.css","deploy":"npm run build; gh-pages -d ./demo","watch":"watch 'npm run build' ./lib","serve":"http-server -p 9090 demo/","start":"npm run build; parallelshell 'npm run serve -s' 'npm run watch -s'"},"repository":{"type":"git","url":"git+https://github.com/SamyPesse/draft-js-prism.git"},"keywords":["draft-js"],"author":{"name":"Samy Pesse","email":"samypesse@gmail.com"},"license":"Apache-2.0","bugs":{"url":"https://github.com/SamyPesse/draft-js-prism/issues"},"homepage":"https://github.com/SamyPesse/draft-js-prism#readme","dependencies":{"extend":"^3.0.0","immutable":"*","prismjs":"^1.5.0"},"devDependencies":{"babel-preset-es2015":"^6.6.0","babel-preset-react":"^6.5.0","babelify":"^7.2.0","browserify":"^13.0.0","draft-js":"^0.7.0","expect":"^1.20.1","gh-pages":"^0.11.0","http-server":"^0.9.0","mocha":"^2.5.3","parallelshell":"2.0.0","react":"^15.1.0","react-dom":"^15.1.0","watch":"^0.18.0"},"gitHead":"8789c835ef829c713c0e0e8ff90de233db53b40f","_id":"draft-js-prism@1.0.3","_shasum":"5dd79ac74f3cd89d788ae4bd1b3e731df3542c7a","_from":".","_npmVersion":"3.7.5","_nodeVersion":"5.1.0","_npmUser":{"name":"samypesse","email":"samypesse@gmail.com"},"dist":{"shasum":"5dd79ac74f3cd89d788ae4bd1b3e731df3542c7a","tarball":"http://registry-npm.ywwl.com/draft-js-prism/download/draft-js-prism-1.0.3.tgz","integrity":"sha512-0CMNtJdSj0T1kewLi04pZxZexAJsqbPjPSlVIy+0YVQorqFFdEjpRG0HbHk5d/xbMfWvlTWTdVAmiaf48I1nOg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIH47OPrZ1e23BF4IX8EqREZQGIkuGZv8zAUucCZ2yzzqAiEAtx7nw6GcYxwjiozhbpmMVUbwruOjp4LyVkXaaFOJZ3o="}],"size":435978,"noattachment":false,"key":"/draft-js-prism/-/draft-js-prism-1.0.3.tgz"},"maintainers":[{"name":"samypesse","email":"samypesse@gmail.com"}],"_npmOperationalInternal":{"host":"packages-16-east.internal.npmjs.com","tmp":"tmp/draft-js-prism-1.0.3.tgz_1465591172942_0.15164126665331423"},"directories":{},"readme":"# draft-js-prism\n\n[![NPM version](https://badge.fury.io/js/draft-js-prism.svg)](http://badge.fury.io/js/draft-js-prism)\n[![Build Status](https://travis-ci.org/SamyPesse/draft-js-prism.svg?branch=master)](https://travis-ci.org/SamyPesse/draft-js-prism)\n\n`draft-js-prism` is a decorator for DraftJS to highlight code blocks using [Prism](https://github.com/PrismJS/prism). It only decorates code blocks with syntax highlighting, if you're interested in providing a correct edition UX for code blocks, take a look at [draft-js-code](https://github.com/SamyPesse/draft-js-code).\n\n![Prism](./preview.gif)\n\n### Installation\n\n```\n$ npm install draft-js-prism prismjs\n```\n\n### Usage\n\n```js\nvar Draft = require('draft-js');\nvar PrismDecorator = require('draft-js-prism');\nvar Prism = require('prismjs')\n\nvar decorator = new PrismDecorator({\n  // Provide your own instance of PrismJS\n  prism: Prism,\n});\nvar editorState = Draft.EditorState.createEmpty(decorator)\n```\n\nYou'll also need to include the css for one of the [Prism themes](https://github.com/PrismJS/prism/tree/gh-pages/themes).\n\nYou can use this decorator combined with others by using [draft-js-multidecorators](https://github.com/SamyPesse/draft-js-multidecorators)\n","publish_time":1465591175908,"_cnpm_publish_time":1465591175908,"dist-tags":{"latest":"1.0.6"}}