├── .gitignore ├── .jshintignore ├── .travis.yml ├── test ├── fixtures │ ├── end-heading.md │ ├── end-heading.html │ ├── blockquote.md │ ├── blockquote.html │ ├── article.md │ └── article.html └── domador.js ├── windowContext.js ├── .editorconfig ├── bower.json ├── .jshintrc ├── virtualWindowContext.js ├── license ├── package.json ├── changelog.markdown ├── readme.markdown ├── dist ├── domador.min.js └── domador.js └── domador.js /.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | npm-debug.log 3 | .DS_Store 4 | Thumbs.db 5 | -------------------------------------------------------------------------------- /.jshintignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | bower_components 3 | dist 4 | example 5 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: node_js 2 | node_js: 3 | - '4' 4 | - '5' 5 | -------------------------------------------------------------------------------- /test/fixtures/end-heading.md: -------------------------------------------------------------------------------- 1 | some [text][1] 2 | 3 | ## some heading 4 | 5 | [1]: /foo 6 | -------------------------------------------------------------------------------- /test/fixtures/end-heading.html: -------------------------------------------------------------------------------- 1 |
some text
2 |title
2 | -------------------------------------------------------------------------------- /license: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright © 2015 Nicolas Bevacqua 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy of 6 | this software and associated documentation files (the "Software"), to deal in 7 | the Software without restriction, including without limitation the rights to 8 | use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of 9 | the Software, and to permit persons to whom the Software is furnished to do so, 10 | subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 17 | FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 18 | COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 19 | IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 20 | CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "domador", 3 | "version": "2.4.4", 4 | "description": "Dependency-free and lean DOM parser that outputs Markdown", 5 | "main": "domador.js", 6 | "scripts": { 7 | "build": "jshint . && browserify -s domador -do dist/domador.js domador.js && uglifyjs -m -c -o dist/domador.min.js dist/domador.js", 8 | "deployment": "git add dist && npm version ${BUMP:-\"patch\"} --no-git-tag-version && git add package.json && git commit -m \"Autogenerated pre-deployment commit\" && bower version ${BUMP:-\"patch\"} && git reset HEAD~2 && git add . && git commit -am \"Release $(cat package.json | jq -r .version)\" && git push --tags && npm publish && git push", 9 | "deploy": "npm run build && npm run deployment", 10 | "test": "tape test/**/*.js" 11 | }, 12 | "repository": { 13 | "type": "git", 14 | "url": "https://github.com/bevacqua/domador.git" 15 | }, 16 | "author": "Nicolas BevacquaLooking at the components that make up [the time to first tweet] measurement, we discovered that the raw parsing and execution of JavaScript caused massive outliers in perceived rendering speed. In our fully client-side architecture, you don’t see anything until our JavaScript is downloaded and executed. The problem is further exacerbated if you do not have a high-specification machine or if you’re running an older browser. The bottom line is that a client-side architecture leads to slower performance because most of the code is being executed on our users’ machines rather than our own.
There are a variety of options for improving the performance of our JavaScript, but we wanted to do even better. We took the execution of JavaScript completely out of our render path. By rendering our page content on the server and deferring all JavaScript execution until well after that content has been rendered, we’ve dropped the time to first Tweet to one-fifth of what it was.
` in addition to `` tags
4 |
5 | # v2.4.1 Pre-order Today
6 |
7 | - Fixed an issue where `domador` wouldn't preserve whitespace in code blocks
8 |
9 | # v2.4.0 Tableau
10 |
11 | - Fixed an issue where `domador` would mess up tables that came after lists
12 | - List item output defaults to a prefix of `'- '` instead of the old `'* '` behavior
13 |
14 | # v2.3.1 Bubble Wrap
15 |
16 | - Fixed an issue where `domador` would pass the internal initial wrapper container to `transform` option
17 |
18 | # v2.3.0 Pin Market
19 |
20 | - Introduced support for `markers`, helpful in a variety of cases
21 |
22 | # v2.2.1 Suspicious Clown
23 |
24 | - Fixed a bug in client-side implementation of `
` support
25 |
26 | # v2.2.0 Murder Central
27 |
28 | - Added `allowFrame` to enable cautious `