X-Git-Url: https://jasonwoof.com/gitweb/?a=blobdiff_plain;f=README.md;h=97d26281a4e16569a35125e92f218d12acaba65d;hb=115352a3056c8456e9998e214458c2b10875e9c7;hp=3d463de5e05271b78754ef2e86903112c74dc121;hpb=4cff8737a670f1aeb0236d18d41bceeab4407db5;p=peach-html5-editor.git diff --git a/README.md b/README.md index 3d463de..97d2628 100644 --- a/README.md +++ b/README.md @@ -1,63 +1,69 @@ -wheic -===== +Peach HTML5 Editor +================== -This project is to build a HTML5 parser, then use that to build a WYSIWYG html -editor for the browser. +Peach Editor is a WYSIWYG HTML5 editor for the browser. -The code is written in CoffeeScript for modern browsers. The HTML5 parser can -also run under node.js. - -Status +Vision ------ -HTML5 parser: all (1581) tests pass. Works in the browser and node.js +Most online HTML editors are built around the "contenteditable" feature of +modern browsers. While this gives developers a lot of features right out of the +box, they must surrender almost complete control over how it works, and thus +we all get stuck using editors that are frustrating and have loads of bugs and +compatibility issues. -WYSIWYG editor: planning stages +Instead of trying to create an ever-expanding set of workarounds for the +quirks, limitations and bugs of different platforms/browsers implementation of +contenteditable, this project aims to create an HTML5 editor that does not use +this feature at all. +This method is much more work, but has the potential to make an editor that is +actually good, since all the code that makes it tick is part of the project, +and its code can be modified. -Quick Start Guide ------------------ +Jason couldn't find an HTML parser in JavaScript that was at all accurate +according to the HTML5 spec, so he wrote one; see ``parser.js``. -1. Open ``test.html`` in your browser. +Current work is going into the GUI. -2. Open the console (right-click, inspect this element, console) -3. After a few seconds, you should see "Tests passed: 1581, Failed: 0" in the - console. +Status +------ -4. Try running the parser in the console, example: +The HTML5 parser: complete component passes the full test suite (1581 tests). - window.wheic.parse_html("

foo

", {fragment: "body"}) +Editor GUI: in early development stages. -For further reading, see "Running Under node.js" below. +Quick Start +----------- + +Open ``index.html`` in a browser (no need for a web server) -Running Under node.js ---------------------- +For further reading, see "Running Under node.js" below. -Dependancies: node.js, coffeescript -You can get CoffeeScript with a command such as this: +Technologies +------------ - apt-get install coffeescript +Programming language: JavaScript -or +HTML5 Parser: Spec compliant, also runs on node.js - npm install -g coffee-script +Interface: Implemented using the DOM api. No ``contenteditable`` or jquery. -Now you can run the test suite like this: - coffee test.coffee +Running Parser with node.js +--------------------------- -Or use the parser from your own code: +The parser can run without the browser, try: - wheic = require './parse-html.coffee' - dom = wheic.parse_html "foo bar" + nodejs parser_tests.js Feedback, Questions, Etc ------------------------ -Please communicate directly with Jason Woofenden by email: jason@jasonwoof.com -or on freenode /msg JasonWoof +Please communicate directly with Jason Woofenden via his website: +https://jasonwoof.com/contact