X-Git-Url: https://jasonwoof.com/gitweb/?a=blobdiff_plain;f=README.md;h=b414c02577296e6fd425f520b75a5ce9bd9a7523;hb=55d296a75a0471af76f0dc05494e9eb98567d314;hp=3d463de5e05271b78754ef2e86903112c74dc121;hpb=4cff8737a670f1aeb0236d18d41bceeab4407db5;p=peach-html5-editor.git diff --git a/README.md b/README.md index 3d463de..b414c02 100644 --- a/README.md +++ b/README.md @@ -38,22 +38,32 @@ Running Under node.js Dependancies: node.js, coffeescript -You can get CoffeeScript with a command such as this: +1. Install node.js https://nodejs.org/en/ - apt-get install coffeescript +2. Install coffeescript. Try: -or + apt-get install coffeescript + or - npm install -g coffee-script + npm install -g coffee-script -Now you can run the test suite like this: +3. You can run the tests directly from coffeescript: - coffee test.coffee + coffee test.coffee -Or use the parser from your own code: +4. Compile to javascript: - wheic = require './parse-html.coffee' - dom = wheic.parse_html "foo bar" + make + +5. Run tests via compiled code: + + nodejs test.js + +5. Try using the parser in your own code: + + var wheic = require('./parse-html.js'); + var dom = wheic.parse_html("

hi

", {fragment: 'body'}); + ... Feedback, Questions, Etc