{"_id":"simple-markdown","_rev":"47-5b3a3a21905268297c52ae37879fe988","name":"simple-markdown","description":"Javascript markdown parsing, made simple","dist-tags":{"latest":"0.7.3","next":"0.7.1"},"versions":{"0.0.2":{"name":"simple-markdown","version":"0.0.2","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test"},"repository":{"type":"git","url":"https://github.com/Khan/simple-markdown.git"},"keywords":["math"],"author":{"name":"Khan Academy"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","devDependencies":{"mocha":"^1.21.5","node-jsx":"git://github.com/spicyj/node-jsx#0.12.0-rc1","react-tools":"0.12.0-rc1"},"dependencies":{"react":"0.12.0-rc1","underscore":"^1.4.4"},"_id":"simple-markdown@0.0.2","_shasum":"c51c75d6258c9adb57c98cacfa3050e2b239ac2c","_from":".","_npmVersion":"2.1.5","_nodeVersion":"0.10.28","_npmUser":{"name":"ariabuckles","email":"aria@khanacademy.org"},"maintainers":[{"name":"ariabuckles","email":"aria@khanacademy.org"}],"dist":{"shasum":"c51c75d6258c9adb57c98cacfa3050e2b239ac2c","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.0.2.tgz","integrity":"sha512-HvbfPyP7xUuigol3ZxQDK5z6b8r4GBck8feaBdXw3hMp43BMngdhpxgHmtlCHKcKcxMXfbRnjJ5Q7I6jSvbBzA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIHBXSk6EIfpIrYiKVU7Vg3w8mfj0/73CgW+Bh14NdHd5AiB3kT8fD6XyJ0zp2ny40qJ/52JqHe8pCU6RDqyr7+DTIQ=="}]},"directories":{},"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.0.3":{"name":"simple-markdown","version":"0.0.3","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test"},"repository":{"type":"git","url":"https://github.com/Khan/simple-markdown.git"},"keywords":["math"],"author":{"name":"Khan Academy"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","devDependencies":{"mocha":"^1.21.5","react-tools":">=0.13.0-rc2","underscore":"^1.4.4","react":">=0.13.0-rc2"},"gitHead":"d495664018e55beceafe003a39ff1cd9c11a4293","_id":"simple-markdown@0.0.3","_shasum":"967020a55e10d56465ff4adfc780c4f7fa17fef3","_from":".","_npmVersion":"2.1.5","_nodeVersion":"0.10.28","_npmUser":{"name":"ariabuckles","email":"aria@khanacademy.org"},"maintainers":[{"name":"ariabuckles","email":"aria@khanacademy.org"}],"dist":{"shasum":"967020a55e10d56465ff4adfc780c4f7fa17fef3","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.0.3.tgz","integrity":"sha512-O8zK8567OuXSd98yMFFokfUbPyzymy43U+UsY352eq59mf2BF32bwFeU5sq0qldCnfN9kyjXFlxqNaFSwG9HfA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIEY0VDSHpYsKv7n8agG8HBS2fwmq9r45pUDM3wpTX7v6AiAWD0rJKrSwS7gPQVb+OaHscZH1Z2VA8w6OGXB4qXv0Lw=="}]},"directories":{},"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.0.4":{"name":"simple-markdown","version":"0.0.4","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["math"],"author":{"name":"Khan Academy"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","devDependencies":{"mocha":"^1.21.5","react-tools":">=0.13.0-rc2","underscore":"^1.4.4","react":">=0.14.0-rc1"},"gitHead":"8e8c94cd9a5aba8148e78fa34f339ce6fa999750","_id":"simple-markdown@0.0.4","_shasum":"a0bb059c8bbdbe72ee01cbff8bf468abec7b7169","_from":".","_npmVersion":"2.14.7","_nodeVersion":"4.2.0","_npmUser":{"name":"ariabuckles","email":"aria@khanacademy.org"},"dist":{"shasum":"a0bb059c8bbdbe72ee01cbff8bf468abec7b7169","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.0.4.tgz","integrity":"sha512-uEhc7Bt7Er19dgPobv9WHeUZy3uuIJ9VLh+A37w9cfObXQ3NtwRkRqaQBzXbNosKzVi6/W8uUEEqfXY5a1Cdjg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCClbGduC/Sf/3mdzggwzyRUTjNgIelx+ZPc39kTY0G0gIgPdhi1RIa0GeviLNL23xkvrvfi4+DhnsicOXVPLDavn4="}]},"maintainers":[{"name":"ariabuckles","email":"aria@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"directories":{},"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.0.5":{"name":"simple-markdown","version":"0.0.5","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Khan Academy"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","devDependencies":{"mocha":"^1.21.5","react-tools":">=0.13.0-rc2","underscore":"^1.4.4","react":">=0.14.0-rc1"},"gitHead":"8b194c5fbe2e17683c2acd4040f128a771a74438","_id":"simple-markdown@0.0.5","_shasum":"a669d8396eeb0c6818426f66cabc6a11b87f86e3","_from":".","_npmVersion":"2.14.7","_nodeVersion":"4.2.0","_npmUser":{"name":"ariabuckles","email":"aria@magoosh.com"},"dist":{"shasum":"a669d8396eeb0c6818426f66cabc6a11b87f86e3","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.0.5.tgz","integrity":"sha512-fkjoYJJOe8g1XqJWbGOxYuiUW3628VmR88LJcCYNW6WPI6wcvmEO0w9t2cMBAmcecUnWHA/Oc4W2DpntbAa5jA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD6IhfbZYzfO03r/khaYyJ2zx6YHbKZfABXv6S3m6+zSQIgcseU+6FtOS14aDE4owd/t+UCZvbRdVc0cmReBA/ZxGg="}]},"maintainers":[{"name":"ariabuckles","email":"aria@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"directories":{},"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.0.6":{"name":"simple-markdown","version":"0.0.6","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Khan Academy"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","devDependencies":{"mocha":"^1.21.5","react-tools":">=0.13.0-rc2","underscore":"^1.4.4","react":">=0.14.0-rc1"},"gitHead":"a455d5048af318825675b7cce6f983676ccdf64f","_id":"simple-markdown@0.0.6","_shasum":"b69216e552328d357aaaffd646835da7a8574ee8","_from":".","_npmVersion":"2.14.7","_nodeVersion":"4.2.0","_npmUser":{"name":"ariabuckles","email":"aria@magoosh.com"},"dist":{"shasum":"b69216e552328d357aaaffd646835da7a8574ee8","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.0.6.tgz","integrity":"sha512-Qh/4rNlrMird8sPsHvydkQ4DBEgJJbvqMkloEp5vWVdKa0TapwtsmKbW2vb0HvfdKjWsDQERdrT84E3+D6J8ig==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQD60+q2f1FXR4tHaBVp9VCJivnjVZYG2JHior7j7YGoZgIhAOD/7pbF4yNxCH56noUJP/nwClFrrS6ArceVbp0KbBbJ"}]},"maintainers":[{"name":"ariabuckles","email":"aria@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"directories":{},"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.0.7":{"name":"simple-markdown","version":"0.0.7","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Khan Academy"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","devDependencies":{"mocha":"^1.21.5","react-tools":">=0.13.0-rc2","underscore":"^1.4.4","react":">=0.14.0-rc1"},"gitHead":"8a57aee77cd84590d9a7d237a427cf2ef5afa436","_id":"simple-markdown@0.0.7","_shasum":"9a0bdf27518ea83b97d9c02660f0cd2acce7cfac","_from":".","_npmVersion":"2.14.7","_nodeVersion":"4.2.0","_npmUser":{"name":"ariabuckles","email":"aria@magoosh.com"},"dist":{"shasum":"9a0bdf27518ea83b97d9c02660f0cd2acce7cfac","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.0.7.tgz","integrity":"sha512-H85qCOviPs3sAVvydXeEBBrBrcAaiN+2+5EylQl4aN3G1wkqJKLXV7aR3dnp0K1g0zm+UPN4uX0P4tnT7nKIJQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDcNUJ57NAidDiWgPkcsKZERegFDO1lW2Qith23h2zmrAIgJlAECIhW1bl++/awTsat4kkw978N4R5spsTdn/vIf98="}]},"maintainers":[{"name":"ariabuckles","email":"aria@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"directories":{},"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.0.8":{"name":"simple-markdown","version":"0.0.8","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Khan Academy"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","devDependencies":{"mocha":"^1.21.5","react-tools":">=0.13.0-rc2","underscore":"^1.4.4","react":">=0.14.0-rc1"},"gitHead":"4d68a37e8a21e9a42c3f674006f4547cebe8e701","_id":"simple-markdown@0.0.8","_shasum":"4d63cbe034b18e6ec86e69779882c1fd01cbf319","_from":".","_npmVersion":"3.5.2","_nodeVersion":"4.2.4","_npmUser":{"name":"ariabuckles","email":"aria@magoosh.com"},"dist":{"shasum":"4d63cbe034b18e6ec86e69779882c1fd01cbf319","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.0.8.tgz","integrity":"sha512-PC7HC3AHp90cscacPFbL3iTq5CKxTesGVXhYQBcS5xROvjdw2SVatTiGJh60ar4udHN8Sz99x9Y1zfrK3E9H8g==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCFF9wyR0Eucw8wxQCITb5XLnAXZGiqqwYRFd025xU3IAIgX+eA9o9BuXXcsX6ex9DAoLODfCR/WBngmo3enL+kYAE="}]},"maintainers":[{"name":"ariabuckles","email":"aria@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"directories":{},"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.0.9":{"name":"simple-markdown","version":"0.0.9","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Khan Academy"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","devDependencies":{"mocha":"^1.21.5","react-tools":">=0.13.0-rc2","underscore":"^1.4.4","react":">=0.14.0-rc1"},"gitHead":"9504ca5f1582f9add845f22b1830e68abd0859da","_id":"simple-markdown@0.0.9","_shasum":"a8ca35d6173e4fc874f251c2bf03a6133b175d3b","_from":".","_npmVersion":"3.5.2","_nodeVersion":"4.2.4","_npmUser":{"name":"ariabuckles","email":"aria@magoosh.com"},"dist":{"shasum":"a8ca35d6173e4fc874f251c2bf03a6133b175d3b","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.0.9.tgz","integrity":"sha512-3Gif39MWnapoHix530SPxtTwQQOtJeF1dlp6/6TvJv65ScU/+hAAiZgPT2aW5CoJPQ66p9ZQY13sgXINwbTmIw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDjPyGTIaQ+RH/RApi4ZazwDFdz2xqINZ8En7P/RebOawIgMdMQeq9K5HM+5nWOACFBgFGgHYtQeVO5/Q7Xg6dLiKc="}]},"maintainers":[{"name":"ariabuckles","email":"aria@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmOperationalInternal":{"host":"packages-9-west.internal.npmjs.com","tmp":"tmp/simple-markdown-0.0.9.tgz_1454357549950_0.18818354699760675"},"directories":{},"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.1.0":{"name":"simple-markdown","version":"0.1.0","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Khan Academy"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","devDependencies":{"mocha":"^2.5.3","react":"^15.1.0","react-dom":"^15.1.0","uglify-js":"^2.6.2","underscore":"^1.4.4"},"gitHead":"c9c0352bf6b36ae0ca95b9995646b70f7763fb89","_id":"simple-markdown@0.1.0","_shasum":"df11ed02e255204c0c85446aa0d5f7e2c6816abf","_from":".","_npmVersion":"3.5.2","_nodeVersion":"4.2.4","_npmUser":{"name":"ariabuckles","email":"aria@magoosh.com"},"dist":{"shasum":"df11ed02e255204c0c85446aa0d5f7e2c6816abf","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.1.0.tgz","integrity":"sha512-8cPN6TJON9AmH80Crz1jKW8Gk1yjq+CimSAh8jqLoaGGXH8zmhdLZ8ZcXmAOokzpDh3WCYnr4yj7KH5oY82hTw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQC7FSB0h1HB3ahlWghA3F/+dJ4CUVkcHQlV5hygTdgSNgIhANRfk/FroP0WSrCLDfp9IBcN0E46ok833qPU0xf5dVOe"}]},"maintainers":[{"name":"ariabuckles","email":"aria@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmOperationalInternal":{"host":"packages-16-east.internal.npmjs.com","tmp":"tmp/simple-markdown-0.1.0.tgz_1464285661364_0.33022309048101306"},"directories":{},"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.1.1":{"name":"simple-markdown","version":"0.1.1","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Khan Academy"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","devDependencies":{"mocha":"^2.5.3","react":"^15.1.0","react-dom":"^15.1.0","uglify-js":"^2.6.2","underscore":"^1.4.4"},"gitHead":"50b12c8d86a2eaeb859dd98bb9dc2a144ce006c6","_id":"simple-markdown@0.1.1","_shasum":"a867d5bb7077f0a0dcc6eb4298ace67b26d100f7","_from":".","_npmVersion":"3.5.2","_nodeVersion":"4.2.4","_npmUser":{"name":"ariabuckles","email":"aria@magoosh.com"},"dist":{"shasum":"a867d5bb7077f0a0dcc6eb4298ace67b26d100f7","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.1.1.tgz","integrity":"sha512-8HT0UZvkvqzdwLKy11T8rvnyHZEOaRawxo0fSeFVWB9I0nu3DQlHIu2jG1eo7Yh6rN7rAIBTDTRz+dm7VECq9A==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDRj2ha0cJQkfh7vPmJDZedri57mspOuD9oTEVN2KqeCgIhAILwFWrVlW7y4OFBKbX+6ZlEWZxvNzwDu8ZidmH9mx6e"}]},"maintainers":[{"name":"ariabuckles","email":"aria@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/simple-markdown-0.1.1.tgz_1465522523764_0.6948351634200662"},"directories":{},"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.1.2":{"name":"simple-markdown","version":"0.1.2","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Khan Academy"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","devDependencies":{"mocha":"^2.5.3","react":"^15.1.0","react-dom":"^15.1.0","uglify-js":"^2.6.2","underscore":"^1.4.4"},"gitHead":"6082c2cb2ffac287da3b3ca2fa64524efaad6815","_id":"simple-markdown@0.1.2","_shasum":"3c1510fe40bd9ea067717b8a533c9cf36325b413","_from":".","_npmVersion":"3.5.2","_nodeVersion":"4.2.4","_npmUser":{"name":"ariabuckles","email":"aria@magoosh.com"},"dist":{"shasum":"3c1510fe40bd9ea067717b8a533c9cf36325b413","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.1.2.tgz","integrity":"sha512-JHWOqed+slWqGTOWsSmbb8LM2aZfk63UI38nZIEc3JoI5WhofmtfrhFsLu0fhz8Wc+FMn/wwHAxf+Gq35d04FQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICoMjGXMYbTU7XgoX22tpm00iuwuAfG7kK5bIROt62oKAiBLDGuxhM/UfCvoH4/mt8udFBu3NyroYGNvJR3QA036Qg=="}]},"maintainers":[{"name":"ariabuckles","email":"aria@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmOperationalInternal":{"host":"packages-16-east.internal.npmjs.com","tmp":"tmp/simple-markdown-0.1.2.tgz_1476737962134_0.13714078906923532"},"directories":{},"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.2.0":{"name":"simple-markdown","version":"0.2.0","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Khan Academy"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","devDependencies":{"mocha":"^2.5.3","react":"^15.1.0","react-dom":"^15.1.0","uglify-js":"^2.6.2","underscore":"^1.4.4"},"gitHead":"965e159dc8d89218f61c9689eb85827caf950662","_id":"simple-markdown@0.2.0","_shasum":"8e98cf0a148b9da4f9610e426c2b59c31c64aba3","_from":".","_npmVersion":"3.5.2","_nodeVersion":"4.2.4","_npmUser":{"name":"ariabuckles","email":"aria@magoosh.com"},"dist":{"shasum":"8e98cf0a148b9da4f9610e426c2b59c31c64aba3","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.2.0.tgz","integrity":"sha512-oT0SD6Ck+oAoPokG87vCE5ylLmLY/pesmIdZObMGbiWVTBxo2z8l3lJC5mBd5s5Fzp1/oAx5azqkvOOJyxPg5g==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIBXm9kvGFWsdpXok8kqRen3YHxQoCdzwFyGjIj2KPucuAiEAreFYf8sYZNVcjRdd15SbwaXUXjYXKN4OHfPyQWGEXwQ="}]},"maintainers":[{"name":"ariabuckles","email":"aria@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmOperationalInternal":{"host":"packages-16-east.internal.npmjs.com","tmp":"tmp/simple-markdown-0.2.0.tgz_1476738073472_0.5090900319628417"},"directories":{},"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.2.1":{"name":"simple-markdown","version":"0.2.1","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Khan Academy"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","devDependencies":{"mocha":"^2.5.3","react":"^15.1.0","react-dom":"^15.1.0","uglify-js":"^2.6.2","underscore":"^1.4.4"},"gitHead":"af7748138fd50ea937e44c9f8cba750c378bc17c","_id":"simple-markdown@0.2.1","_shasum":"6df51517681f6aab4df1cc980cf6b845bb6b3d33","_from":".","_npmVersion":"3.5.2","_nodeVersion":"4.2.4","_npmUser":{"name":"ariabuckles","email":"aria@magoosh.com"},"dist":{"shasum":"6df51517681f6aab4df1cc980cf6b845bb6b3d33","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.2.1.tgz","integrity":"sha512-K8uOtm5/jKRNhEW2L6PoAgA1DQILMSjgWyYoWvWMOxt7NB1lCIxwm+aPcuyteAwVTuMYQVKhbZWRsHd0qHl8aw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDhlLZkLxHpi10Ttge5cjY9Om/R4bL2IDvvx3l5shp8BAIgOdDeinHK8JcTpriih/SrLh6a3N90zb8ImUVSa+XBonk="}]},"maintainers":[{"name":"ariabuckles","email":"aria@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/simple-markdown-0.2.1.tgz_1476845876873_0.8285407789517194"},"directories":{},"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.2.2":{"name":"simple-markdown","version":"0.2.2","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Khan Academy"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","devDependencies":{"mocha":"^2.5.3","react":"^15.1.0","react-dom":"^15.1.0","uglify-js":"^2.6.2","underscore":"^1.4.4"},"gitHead":"15573725dcb0139f6ed53ce431521c1b292a0b97","_id":"simple-markdown@0.2.2","_npmVersion":"5.3.0","_nodeVersion":"8.2.1","_npmUser":{"name":"ariabuckles","email":"aria@classjourney.org"},"dist":{"integrity":"sha512-AHdtgtmYo7VR48kmm+lzQRJpyjv5G+2hk/4zMH3O1A288u0goKTCHwEFPRNcrqQt5SkmFUXLAycgoH7oxfYOZA==","shasum":"bede9c89274b441ee98c4869e5b27f23c9959b88","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.2.2.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDuqRh7SLdbs8Vt2v2LOI/U2imqZYt3U4+bof5fmo1edwIgeHVs0UTMEzsR2EfR3x7bKSaYPmosx8DSr0QYKlQn8nc="}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown-0.2.2.tgz_1504407856437_0.8286631626542658"},"directories":{},"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.3.0":{"name":"simple-markdown","version":"0.3.0","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Khan Academy"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","devDependencies":{"mocha":"^2.5.3","react":"^15.1.0","react-dom":"^15.1.0","uglify-js":"^2.6.2","underscore":"^1.4.4"},"gitHead":"20b1fefcf2f9aa88f66e1f4a6508832c17ad6f3e","_id":"simple-markdown@0.3.0","_npmVersion":"5.3.0","_nodeVersion":"8.2.1","_npmUser":{"name":"ariabuckles","email":"aria@classjourney.org"},"dist":{"integrity":"sha512-rJzO4esVDNfCuG1xdWNA4dB1MoklWPzR4eakU3Iw8OEMkzOFj2DDxUPH94TGgp4grmfRFMfz4Qap2PqRpYK8ZA==","shasum":"276f6ba7f92efd22aced42019a252f41de233e57","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.3.0.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQChOIbwpMRMGLguWhSUjvVAKZ5ieb8SrsaipSRkj89TUgIgZxwL8Q03eh7rkTWEvMsEL7Ws9u5hi9QqHOxj4a7yrPs="}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown-0.3.0.tgz_1504407928492_0.31960119563154876"},"directories":{},"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.3.1":{"name":"simple-markdown","version":"0.3.1","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Khan Academy"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","devDependencies":{"mocha":"^2.5.3","react":">=15.1.0","react-dom":">=15.1.0","uglify-js":"^2.6.2","underscore":"^1.8.3"},"gitHead":"3d0d2bd973463ae51b2c61d5a05fd0b570d452d3","_id":"simple-markdown@0.3.1","_npmVersion":"5.3.0","_nodeVersion":"8.2.1","_npmUser":{"name":"ariabuckles","email":"aria@classjourney.org"},"dist":{"integrity":"sha512-deShqkf7SMufWVbVRrUmUt0vdJ1dVWV4XC1NPzCdymKpVvQyLVz+TjmXXqu6fhmJP9iyw14pksz40jGSLDP5fQ==","shasum":"de0d414301f87f1edfdcb8d18366c377545e42ed","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.3.1.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCICdZl7IjqjPukITLJdWsdKXukkxl6j8eauA0VSvrDw6kAiEA96WCWtRvADPppyzeM18Xiifa6sbPx1MZSu1vEXAWmYU="}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown-0.3.1.tgz_1505329638178_0.3901402505580336"},"directories":{},"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.3.2":{"name":"simple-markdown","version":"0.3.2","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test && size-limit","size":"size-limit"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Khan Academy"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","devDependencies":{"mocha":"^2.5.3","react":"^16.1.0","react-dom":"^16.1.0","size-limit":"^0.13.1","uglify-js":"^2.6.2","underscore":"^1.8.3"},"size-limit":[{"path":"simple-markdown.js","limit":"4 KB"}],"gitHead":"cb2dca0e51bf72e11fe29b228db9321bf90ba32d","_id":"simple-markdown@0.3.2","_npmVersion":"5.3.0","_nodeVersion":"8.2.1","_npmUser":{"name":"ariabuckles","email":"aria@classjourney.org"},"dist":{"integrity":"sha512-ckO9v4bCejAYZc1Kwz5hpAAQxa8l5EAC5yGntA+CiYwNjKdHHeikf1UIBsGezq7shT4IjReg/UTkhE1p7bUtvg==","shasum":"eb3902dc3bcf74fdfc1883230286dcadea870dc0","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.3.2.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIH/ki60a1fjqKi0ZgcU0kbNtBWSaHJcZw5yqjQz0wCXqAiAGM9aZDTeHX3bo9hVL3Dt1sgpi2AR5qIIIgOx53MH9Tg=="}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown-0.3.2.tgz_1515192795881_0.4861784491222352"},"directories":{},"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.3.3":{"name":"simple-markdown","version":"0.3.3","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test && size-limit","size":"size-limit"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Khan Academy"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","devDependencies":{"mocha":"^2.5.3","react":"^16.1.0","react-dom":"^16.1.0","size-limit":"^0.13.1","uglify-js":"^2.6.2","underscore":"^1.8.3"},"size-limit":[{"path":"simple-markdown.js","limit":"4 KB"}],"gitHead":"3e926f5a1bdc3b2acb4549e423e9e27f2fbdd154","_id":"simple-markdown@0.3.3","_npmVersion":"5.6.0","_nodeVersion":"9.6.1","_npmUser":{"name":"ariabuckles","email":"aria@classjourney.org"},"dist":{"integrity":"sha512-2qx5eXuRP/2pH+I/EQYVzZ/XgGHg2IAHEfIZkrPbtfiOkSkd4Q1mswE7LG77I+TDz2eb2Vx2K/v/Ul0llFhplg==","shasum":"a2c50114aa0aa9794cf30fb91b57965599b3ff00","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.3.3.tgz","fileCount":12,"unpackedSize":204616,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIEotDWxnEZqsm4dfmqyIFLBgil+d8o5Ubx+4+XZQ1FJ4AiALiz3DNFt8yEuRuFEhUoT8UQSVHd1AofUaUe8NaE/dow=="}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown_0.3.3_1520730820753_0.7296579475814"},"_hasShrinkwrap":false,"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"1.0.0-alpha.0":{"name":"simple-markdown","version":"1.0.0-alpha.0","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test","prepublishOnly":"make minify","size":"size-limit"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Aria Buckles"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","devDependencies":{"flow-bin":"0.61.*","flow-typed":"^2.1.5","mocha":"^3.5.0","react":"^16.1.0","react-dom":"^16.1.0","size-limit":"^0.13.1","uglify-js":"^2.6.2","underscore":"^1.8.3"},"size-limit":[{"path":"simple-markdown.js","limit":"5 KB"}],"readme":"simple-markdown\n===============\n\nsimple-markdown is a markdown-like parser designed for simplicity\nand extensibility.\n\n[Change log](https://github.com/Khan/simple-markdown/releases)\n\nPhilosophy\n==========\n\nMost markdown-like parsers aim for [speed][marked] or\n[edge case handling][CommonMark].\nsimple-markdown aims for extensibility and simplicity.\nIt has no external dependencies, at is 5 KB after minification and gzipping,\nand is a single ES5-compatable js file, which can be included via `require`\nor a global variable.\n\n[marked]: https://github.com/chjj/marked\n[CommonMark]: https://github.com/jgm/CommonMark\n\nMany websites using markdown-like languages have custom extensions,\nsuch as `@`mentions or issue number linking. Unfortunately, it's often\nhard to extend many markdown parsers for use cases like these.\nsimple-markdown is designed to allow simple customization and extension.\n\nAt Khan Academy, we use simple-markdown to format\nover half of our math exercises, because we need\n[markdown extensions][PerseusMarkdown] for math text and\ninteractive widgets.\n\n[Discord][Discord] uses simple-markdown for text chat, including username/mention\nlinking and custom emoji rendering.\n\n[PerseusMarkdown]: https://github.com/Khan/perseus/blob/master/src/perseus-markdown.jsx\n[Discord]: https://discordapp.com\n\nsimple-markdown is [MIT licensed][LICENSE].\n\n[LICENSE]: https://github.com/Khan/simple-markdown/blob/master/LICENSE\n\nGetting started\n===============\n\n## Setup\n\nTo run these examples in node or a browserify/webpack environment,\nyou should run `npm install` in the simple-markdown folder or\n`npm install simple-markdown` in your project's folder.\nThen you can acquire the `SimpleMarkdown` variable with:\n\n```javascript\n    var SimpleMarkdown = require(\"simple-markdown\");\n```\n\n\n## Basic usage\n\nsimple-markdown has some convenience functions if you don't need to\ndo much customization on the parsing or rendering ('outputting').\n\n```javascript\n    // For Html applications:\n    SimpleMarkdown.markdownToHtml('Hi!')\n    => '<div class=\"paragraph\">Hi!</div>'\n\n    // For React applications:\n    <SimpleMarkdown.ReactMarkdown source={\"Hi!\"} />\n    => <ReactMarkdown><div>Hi!</div></ReactMarkdown>\n    // or\n    SimpleMarkdown.markdownToReact('Hi!')\n    => [<div class=\"paragraph\">Hi!</div>]\n\n```\n\n\n## Advanced usage\n\nIf you're looking for a more custom use-case, it will help to cover some\nfundamentals powering simple-markdown, so that we can extend on them. I\nrecommend continuing to read the next section! If you're looking for an\nAPI reference or type reference, you can find that at the end of this\ndocumentation!\n\nBut just as an example of what you can do with simple-markdown, here's\nwhat an implementation of adding `@` handles / mentions\n(like [@ariabuckles](https://github.com/ariabuckles))\nlooks like:\n\n```javascript\nvar rules = Object.assign({}, SimpleMarkdown.defaultRules, {\n    mention: {\n        order: SimpleMarkdown.rules.text.order - 0.5,\n        match: function(source) {\n            return /^@(\\w+)/.exec(source);\n        },\n        parse: function(capture) {\n            return {\n                username: capture[1]\n            };\n        },\n        react: function(node) {\n            return <a href={\"https://github.com/\" + node.username}>\n                @{node.username}\n            </a>;\n        },\n        html: function(node, recurseOutput) {\n            return '<a href=\"' + node.username + '\">@' + node.username + '</a>';\n        },\n    },\n};\n\nvar parse = SimpleMarkdown.parserFor(rules);\nvar htmlOutput = SimpleMarkdown.outputFor(rules, 'html');\nvar reactOutput = SimpleMarkdown.outputFor(rules, 'react');\n\nvar markdownToHtml = function(source) {\n    return htmlOutput(parse(source));\n};\nvar markdownToReact = function(source) {\n    return reactOutput(parse(source));\n};\n```\n\n\n------------------------------------------------------------------------------\n\n*The rest of this guide covers advanced usage, and is only necessary if\nyou're making your own extensions. If so, bravo and read on!*\n\n------------------------------------------------------------------------------\n\n\nConcepts\n========\n\nTo customize how simple-markdown works, we'll need to first cover some\nconcepts simple-markdown uses internally.\n\n\n## Parsed Content Tree (AST) : `var parsedContentTree`\n\nA parsed content tree is a representation of the parsed markdown as a JSON tree\nstructure. simple-markdown uses parsed content trees for intermediate\nrepresentation: after parsing the markdown, but before rendering/outputting\nit to react/html. Let's look at an example:\n\n```markdown\nThis paragraph has some *emphasized text*.\n```\n\nThe parsed content tree for the above markdown is:\n\n```javascript\nvar parsedContentTree = SimpleMarkdown.defaultBlockParse(\n    \"This paragraph has some *emphasized text*.\"\n);\n=> [\n    {\n        \"type\": \"paragraph\"\n        \"content\": [\n            {\n                \"type\": \"text\"\n                \"content\": \"This paragraph has some \",\n            },\n            {\n                \"type\": \"em\"\n                \"content\": [\n                    {\n                        \"type\": \"text\"\n                        \"content\": \"emphasized text\",\n                    }\n                ],\n            },\n            {\n                \"type\": \"text\"\n                \"content\": \".\",\n            }\n        ],\n    }\n]\n```\n\nIt's not important to be familiar with the details of the above tree\nstructure, but it is important that a parsed content tree is what\n`parse` returns\n\n\n## Parser : `function parse(source, state) => parsedContentTree`\n\nA parser is a function that takes a markdown string and returns a syntax tree.\n(*parsers also accept an optional `state` parameter, which can be used to pass\ninformation through the parsing to custom parse rules.*)\n\nsimple-markdown has some pre-built parsers for you, or provides you ways\nto build your own custom ones:\n\n```javascript\n// Parse the markdown `source` string as block elements\nvar parsedContentTree = SimpleMarkdown.defaultBlockParse(source)\n\n// Parse the markdown `source` as a single line, with no wrapping <div>\nvar parsedContentTree = SimpleMarkdown.defaultInlineParse(source)\n```\n\n\n## Outputter : `function output(parsedContentTree, state) => JSX / HTML`\n\nAn outputter / output function is a function that takes a syntax tree and\nreturns react nodes or html (or a custom output format)\n\nAgain, simple-markdown has some pre-built outputters:\n\n```javascript\n// Turn a syntax tree into react nodes for rendering with react\nvar jsx = SimpleMarkdown.defaultReactOutput(parsedContentTree)\n\n// Turn a syntax tree into an html string for rendering directly via html\nvar html = SimpleMarkdown.defaultHtmlOutput(parsedContentTree)\n```\n\n\n## Rules : `var rules = {...}`\n\nRules are a set of syntax rules supported by a markdown parser/outputter,\nsuch as `paragraphs`, `# headings`, `**bold (strong) text**`, `[links][1]`, etc.\n\nRules specify what syntax is parsed, and how it is parsed.\n\nsimple-markdown comes with a set of rules implementing Github-Flavoured\nMarkdown, which is recommended as a starting base for any rules object you\ndefine:\n\n```javascript\nvar rules = Object.assign({}, SimpleMarkdown.defaultRules, {\n    // ... (rule customizations go here)\n});\n```\n\nAs in the above example, [Object.assign][Object_assign] or\n[_.extend][underscore_extend] is recommended for creating custom rules.\nYou should not need to mutate `SimpleMarkdown.defaultRules`.\n\n[Object_assign]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/assign\n[underscore_extend]: http://underscorejs.org/#extend\n\n\n## State: `var state = {...}`\n\n`state` is an optional parameter to parsers and outputters which is passed\nto each parse/output rule. It is a plain javascript object which may be\nmodified by the rules as parsing or outputting is running. This allows\ngiving extra runtime information to rules, as well as extracting information\ngained during parsing/outputting.\n\nsimple-markdown uses state to pass around some internal information, and you\ncan add custom information to it for powerful extensions, which is covered\nunder the *Advanced Extensions* section later.\n\nThe following public fields on `state` can be used to interact with\nsimple-markdown:\n\n```\nstate.inline  // true if inside a context where block rules are not permitted\n\nstate.disableAutoBlockNewlines  // setting this to true turns off the automatic\n                                // addition of '\\n\\n' for block parsing\n\nstate.key  // the suggested react key for the current node\n           // use this for the react key when implementing a custom rule\n```\n\nsimple-markdown reserves all fields beginning with `_` on `state` for future\ninternal use. Currently, the following are used:\n\n```\nstate._defs  // used for link/image url definitions ([1]: http://example.com)\nstate._refs  // used for references to url definitions ([link][1])\nstate._list  // used for parsing tight lists\n```\n\n\nExtensions\n==========\n\n## Extension fundamentals\n\nExtensions add or remove functionality from default simple-markdown by\ncustomizing what rules the parser and outputter use. Very much of the\nparser and outputter's functionality can be controlled via custom\nrules. Rules specify what syntax is parsed, how it is parsed, and how\nit is output (to react/jsx, html, or another format).\n\nTo customize rules, we want to create a new `rules` object, generally\nincluding some or all of the default simple-markdown rules, and potentially\nsome of our own. I recommend using [Object.assign][Object_assign] or\n[_.extend][underscore_extend] to create this rules object based on\nsimple-markdown's default rules (`SimpleMarkdown.defaultRules`):\n\n```javascript\n// Note how we copy the rules to a new empty object, since\n// Object.assign mutates the first paramter:\nvar rules = Object.assign({}, SimpleMarkdown.defaultRules, {\n    // any new rules would go here\n});\n```\n\nAs a simple example, it is easy to remove support for a specific syntax rule\nfrom simple-markdown. For example, you might decide that your website should\njust show `*`s and `_`s instead of trying to transform them into bold and\nitalics (okay, I admit this is unlikely, but some of us do enjoy plain text!).\nTo do this, we can simply make a copy of the rules object and remove the `em`\n(emphasis/italics) rule, `strong` (bold) rule, and `u` (underline) rule:\n\n```javascript\n// first make a copy of the rules:\nvar rules = Object.assign({}, SimpleMarkdown.defaultRules);\n// then remove the hr rule:\ndelete rules.em;\ndelete rules.strong;\ndelete rules.u;\n\n// Perhaps more canonically, we can remove the rule purely using\n// Object.assign:\nvar rules = Object.assign({}, SimpleMarkdown.defaultRules, {\n    em: null,\n    strong: null,\n    u: null,\n});\n```\n\nThen, we need to build our parser and outputter from our new rules\nobject. We can do this with `SimpleMarkdown.parserFor` and\n`SimpleMarkdown.outputFor`.\n\n```javascript\nvar parse = SimpleMarkdown.parserFor(rules);\nvar output = SimpleMarkdown.outputFor(rules, 'html');\n// alternatively, if using react:\n// var output = SimpleMarkdown.outputFor(rules, 'react');\n```\n\nNow, to do some parsing and outputting without hr support, we can\nuse our new `parse` and `output` functions:\n\n```javascript\nvar parsedContentTree = parse('look, no more *italics*!');\n=> [ { type: 'paragraph', content: [ [Object], [Object], [Object], [Object], [Object] ] } ]\nvar html = output(parsedContentTree);\n=> '<div class=\"paragraph\">look, no more *italics*!</div>'\n\n// Or, we might want to group those operations together in a single function:\nvar markdownToHtml = function(source, state) {\n    var parsedContentTree = parse(source, state);\n    var html = output(parsedContentTree, state);\n    return html;\n};\n```\n\n\n## Adding rules with extensions\n\nOn the other hand, if we want to add support for a new syntax to our\nmarkdown parser, we'll need to write our own rule.\n\nA rule is an object consisting of [at least] the following fields:\n\n * **`order`**`: <number>` :\n   a number specifying the order/precedence of a rule relative to\n   other rules. Rules with lower order numbers will be processed\n   first. If you have two rules that both match markdown text\n   starting with the same character, it can matter which one is\n   processed first.\n   `order` should be unique among the rules, and to facilitate that,\n   `SimpleMarkdown.defaultRules` are all integers starting at 0,\n   so that extensions can base their rule order off of orders of\n   pre-existing rules, i.e.\n   `order: SimpleMarkdown.rules.text.order - 0.5`\n   will place a rule immediately before `text`, which is always the\n   last simple-markdown rule, as it matches anything unmatched by\n   earlier rules.\n\n * **`match`**`: function(source) => capture` :\n   a function which takes the markdown source beginning from the current parse\n   position, and returns a capture: an array-like object with the element at\n   index 0 set to the full text from the source which matches the rule. The\n   common way to do this is to return the result of a call to `.exec` on a\n   regex (which must begin with `^`):\n   `return /^\\@(\\w+)/.exec(source);`.\n   Other fields on this object, such as indexes 1+ for parenthetical regex\n   captures, may be used to provide more detailed information about this match\n   to the other functions for this rule.\n\n * **`parse`**`: function(capture) => node` :\n   a function which takes the result of\n   `match` (an array-like capture probably the result of calling `.exec` on\n   a regex), and returns a parseTreeContent node: an object containing\n   information about this block of syntax. For example, here is a node for\n   the link: `[link text](http://example.com)`\n   \n   ```\n   {\n       \"type\": \"link\",\n       \"content\": [\n           {\n               \"type\": \"text\"\n               \"content\": \"link text\",\n           }\n       ],\n       \"target\": \"http://example.com\"\n   }\n   ```\n\n   Note two semi-special fields on this object:\n   First, `type` specifies the name\n   of the rule that matched it. Idiomatically this field is omitted and\n   simple-markdown will populate it for you, and use it to determine\n   which `parse` function a given node should be processed by.\n   Second, `content` is typically a parse tree of the text content of\n   the node, if such content exists.\n\n * **`react`**`: function(node) => jsx` :\n   a function which takes the result of the `parse` field (above) for this\n   rule and returns react elements (jsx) as the final output of this\n   bit of markdown to render.\n   This field is only necessary if you are using simple-markdown to output\n   to react. If you are using html or a different format altogether, it\n   isn't required.\n\n * **`html`**`: function(node) => htmlString` :\n   a function which takes the result of the `parse` field (above) for this\n   rule and returns an html string as the final output of this bit of\n   markdown to turn into html.\n   This field is only necessary if you are using simple-markdown to output\n   to html.\n\nThe above covers the fundamental properties of a rule. More detailed information\non the above fields, their optional parameters, and the optional field\n`quality`, can be found in the advanced extensions portion of this documentation\nand in the API reference at the end of this documentation.\n\n\nLet's add support for `@` handles / user mentions. We'll write our own\nrule for this, and call it `mention` (though the name is arbitrary, it\njust needs to not conflict with any other rule name)\n\n```javascript\nvar rules = Object.assign({}, SimpleMarkdown.defaultRules, {\n    mention: {\n        order: SimpleMarkdown.rules.text.order - 0.5,\n\n        match: function(source) {\n            // This regex matches @handles at the current source position (^)\n            return /^@(\\w+)/.exec(source);\n        },\n\n        parse: function(capture) {\n            // capture is the result from `/^@(\\w+)/.exec(source)` in `match`\n            // capture[1] is the (\\w+) name group.\n            // We just return an object representing what this node is\n            return {\n                type: 'mention',  // optional; inferred if omitted\n                username: capture[1]\n            };\n        },\n\n        react: function(node) {\n            // node is the object returned by `parse`\n\n            // Let's just make the link now!\n            return <a href={\"https://github.com/\" + node.username>\n                @{node.username}\n            </a>;\n        },\n\n        html: function(node, recurseOutput) {\n            // node is the object returned by `parse`\n\n            // This time in html~\n            return '<a href=\"' + node.username + '\">@' + node.username + '</a>';\n        },\n    },\n});\n```\n\nOnce we have our new rules object, we can create the full parser and outputter\nwith `SimpleMarkdown.parserFor` and `SimpleMarkdown.outputFor`:\n\n\n## Rules which contain other markdown : using `recursiveParse / recursiveOutput`\n\nSome rules you might want to add will contain other markdown content\nthemselves. For example, the bold and italics (technically, strong and em)\nrules are used for formatting text, and that text might have other markdown\nconstructions, like a link: `*italic text with a [link](http://example.com)*`.\n\nIn order to support rules like this, our `parse` and `output` rule fields\nwill need to parse and output the nested markdown, in addition to any\nformatting.\n\nLet's say we wanted to implement Reddit's `^`, which raises text into a\nsuperscript. It supports two forms:\n\n`^word` : raises a word into a superscript\n\n`^(multiple words)` : raises multiple words into a superscript\n\nBoth of these formats support nested markdown. For example, you can\nnest superscripts using `^higher^higher^and^higher`, or you can\nadd italics inside a multiple word superscript: `^(some *italic* text)`.\n\nTo implement this nesting, we'll use the recursive parameters\n`recursiveParse` and `recursiveOutput`. These are the second parameters\npassed to each `parse` and output (`react` / `html`) rules, and tell\nsimple-markdown to recursively parse or output some content as markdown.\n\nLet's take a look at what it looks like in action:\n\n```javascript\nvar rules = Object.assign({}, SimpleMarkdown.defaultRules, {\n    superscript: {\n        order: SimpleMarkdown.defaultRules.text.order - 0.5,\n\n        match: function(source) {\n            if (!state.inline) {\n                return null;\n            }\n            // This regex matches @handles at the current source position (^)\n            // match a `^` followed by either non-whitespace, non-()s, or\n            // a ( followed by non `)`s followed by a `)`\n            return /^\\^(?:([^\\s\\(\\)]+)|\\(([^\\)]+)\\))/.exec(source);\n        },\n\n        parse: function(capture, recursiveParse) {\n            return {\n                // simple-markdown automatically sets type to 'superscript',\n                // as that's the name of this rule\n\n                // we want to parse the parenthesized group of the capture\n                // as markdown as well, so we pass it to `recursiveParse`\n                content: recursiveParse(capture[1] || capture[2]),\n            };\n        },\n\n        react: function(node, recursiveOutput) {\n            // node is the object returned by `parse`\n\n            // output a superscript tag around the markdown output for\n            // the node's parsed content\n            return <sup>\n                {recurseOutput(node.content)}\n            </sup>;\n        },\n\n        html: function(node, recurseOutput) {\n            // This time in html~\n            return '<sup>' + recurseOutput(node.content) + '</sup>';\n        },\n    },\n});\n```\n\n## Rules which need special input or output : using `state`\n\nSome rules require more context than is available strictly from the\nmarkdown source. For example, if we wanted to build a footnote\nsyntax for citations/references, we might want to automatically number\nthe footnotes so that they don't require manually changing if we\nadd a new footnote.\n\nFor example, let's examine the following potential syntax:\n\n```\nThis is some text ^[This is a footnote]\n```\n\nwhich we'd like to render as:\n\n> This is some text¹\n> \n> ¹ This is a footnote\n\nWhat number footnote we are on isn't something we can extract from\nthe syntax of `^[]`. It's based on the number of previous footnotes\nwe've seen while parsing. To determine that, we're going to have to\nuse a third parameter to `parse` : `state`.\n\nIn addition to `capture` and `recurseParse`, simple-markdown will\npass the parameter `state` to each rule's `parse` field. `state` is\na plain, mutable javascript object which rules may modify, as explained\nin [the concepts section above][state_section].\n\n\n[state_section]: #state\n\n\n# TODO:\n\nThen let's get a basic markdown parser and outputter.\n`SimpleMarkdown` provides default parsers/outputters for\ngeneric markdown:\n\n```javascript\n    var mdParse = SimpleMarkdown.defaultBlockParse;\n    var mdOutput = SimpleMarkdown.defaultOutput;\n```\n\n`mdParse` can give us a syntax tree:\n\n```javascript\n    var syntaxTree = mdParse(\"Here is a paragraph and an *em tag*.\");\n```\n\nLet's inspect our syntax tree:\n\n```javascript\n    // pretty-print this with 4-space indentation:\n    console.log(JSON.stringify(syntaxTree, null, 4));\n    => [\n        {\n            \"content\": [\n                {\n                    \"content\": \"Here is a paragraph and an \",\n                    \"type\": \"text\"\n                },\n                {\n                    \"content\": [\n                        {\n                            \"content\": \"em tag\",\n                            \"type\": \"text\"\n                        }\n                    ],\n                    \"type\": \"em\"\n                },\n                {\n                    \"content\": \".\",\n                    \"type\": \"text\"\n                }\n            ],\n            \"type\": \"paragraph\"\n        }\n    ]\n```\n\nThen to turn that into an array of React elements, we can\ncall `mdOutput`:\n\n```javascript\n    mdOutput(syntaxTree)\n    => [ { type: 'div',\n        key: null,\n        ref: null,\n        _owner: null,\n        _context: {},\n        _store: { validated: false, props: [Object] } } ]\n```\n\n\nAdding a simple extension\n=========================\n\nLet's add an underline extension! To do this, we'll need to create\na new rule and then make a new parser/outputter. The next section\nwill explain how all of these steps work in greater detail. (To\nfollow along with these examples, you'll also need\n[underscore][underscore].)\n\n[underscore]: http://underscorejs.org/\n\nFirst, we create a new rule. We'll look for double underscores\nsurrounding text.\n\nWe'll put underlines right\nbefore `em`s, so that `__` will be parsed before `_`\nfor emphasis/italics.\n\nA regex to capture this would look something\nlike `/^__([\\s\\S]+?)__(?!_)/`. This matches `__`, followed by\nany content until it finds another `__` not followed by a\nthird `_`.\n\n```javascript\n    var underlineRule = {\n        // Specify the order in which this rule is to be run\n        order: SimpleMarkdown.defaultRules.em.order - 0.5,\n        \n        // First we check whether a string matches\n        match: function(source) {\n            return /^__([\\s\\S]+?)__(?!_)/.exec(source);\n        },\n        \n        // Then parse this string into a syntax node\n        parse: function(capture, parse, state) {\n            return {\n                content: parse(capture[1], state)\n            };\n        },\n        \n        // Finally transform this syntax node into a\n        // React element\n        react: function(node, output) {\n            return React.DOM.u(null, output(node.content));\n        },\n\n        // Or an html element:\n        // (Note: you may only need to make one of `react:` or\n        // `html:`, as long as you never ask for an outputter\n        // for the other type.)\n        html: function(node, output) {\n            return '<u>' + output(node.content) + '</u>';\n        },\n    };\n```\n\nThen, we need to add this rule to the other rules:\n\n```javascript\n    var rules = Object.assign({}, SimpleMarkdown.defaultRules, {\n        underline: underlineRule\n    });\n```\n\nFinally, we need to build our parser and outputters:\n\n```javascript\n    var rawBuiltParser = SimpleMarkdown.parserFor(rules);\n    var parse = function(source) {\n        var blockSource = source + \"\\n\\n\";\n        return rawBuiltParser(blockSource, {inline: false});\n    };\n    // You probably only need one of these: choose depending on\n    // whether you want react nodes or an html string:\n    var reactOutput = SimpleMarkdown.outputFor(rules, 'react');\n    var htmlOutput = SimpleMarkdown.outputFor(rules, 'html');\n```\n\nNow we can use our custom `parse` and `output` functions to parse\nmarkdown with underlines!\n\n```javascript\n    var syntaxTree = parse(\"__hello underlines__\");\n    console.log(JSON.stringify(syntaxTree, null, 4));\n    => [\n        {\n            \"content\": [\n                {\n                    \"content\": [\n                        {\n                            \"content\": \"hello underlines\",\n                            \"type\": \"text\"\n                        }\n                    ],\n                    \"type\": \"underline\"\n                }\n            ],\n            \"type\": \"paragraph\"\n        }\n    ]\n    \n    reactOutput(syntaxTree)\n    => [ { type: 'div',\n        key: null,\n        ref: null,\n        _owner: null,\n        _context: {},\n        _store: { validated: false, props: [Object] } } ]\n\n    htmlOutput(syntaxTree)\n\n    => '<div class=\"paragraph\"><u>hello underlines</u></div>'\n```\n\n\nBasic parsing/output API\n========================\n\n#### `SimpleMarkdown.defaultBlockParse(source)`\n\nReturns a syntax tree of the result of parsing `source` with the\ndefault markdown rules. Assumes a block scope.\n\n#### `SimpleMarkdown.defaultInlineParse(source)`\n\nReturns a syntax tree of the result of parsing `source` with the\ndefault markdown rules, where `source` is assumed to be inline text.\nDoes not emit `<p>` elements. Useful for allowing inline markdown\nformatting in one-line fields where paragraphs, lists, etc. are\ndisallowed.\n\n#### `SimpleMarkdown.defaultImplicitParse(source)`\n\nParses `source` as block if it ends with `\\n\\n`, or inline if not.\n\n#### `SimpleMarkdown.defaultReactOutput(syntaxTree)`\n\nReturns React-renderable output for `syntaxTree`.\n\n#### `SimpleMarkdown.defaultHtmlOutput(syntaxTree)`\n\nReturns the html string output for `syntaxTree`\n\n\nExtension Overview\n==================\n\nElements in simple-markdown are generally created from rules.\nFor parsing, rules must specify `match` and `parse` methods.\nFor output, rules must specify a `react` or `html` method\n(or both), depending on which outputter you create afterwards.\n\nLet's build an example rule to recognize `@` handles, like @ariabuckles\n\n```javascript\n    atHandle: {\n        match: function(source) {\n            // `match` returns the result of a regex exec\n            // such a regex should always begin with `^`, as it will\n            // always be called to check whether the beginning of the\n            // input matches the rule\n            // This regex matches @handles at the current source position (^)\n            return /^\\@([a-zA-Z_]+)/.exec(source);\n        },\n        parse: function(capture) {\n            // `parse` returns the AST node for this rule, given\n            // `capture`, the result of a successful `match` call\n\n            // capture[1] is the ([a-zA-Z_]+) name group from the `match` regex\n            return {\n                type: 'atHandle',\n                username: capture[1]\n            };\n        },\n        react: function(node) {\n            // given an AST node from `parse`, how should we render it in react?\n            // (Note: you don't need this if you are only rendering to html)\n\n            return <a href={\"https://github.com/\" + node.username>\n                @{node.username}\n            </a>;\n        },\n        html: function(node, recurseOutput) {\n            // or, how should we render this node in html\n            // (Note: you don't need this if you are rendering to react)\n\n            return '<a href=\"' + node.username + '\">@' + node.username + '</a>';\n        },\n    },\n```\n\nBy using the above rule, we can transform `@ariabuckles` into @ariabuckles\n\nLet's look at those three methods in more detail.\n\n#### `match(source, state, lookbehind)`\n\nsimple-markdown calls your `match` function to determine whether the\nupcoming markdown source matches this rule or not.\n\n`source` is the upcoming source, beginning at the current position of\nparsing (source[0] is the next character).\n\n`state` is a mutable state object to allow for more complicated matching\nand parsing. The most common field on `state` is `inline`, which all of\nthe default rules set to true when we are in an inline scope, and false\nor undefined when we are in a block scope.\n\n`lookbehind` is the string previously captured at this parsing level, to\nallow for lookbehind. For example, lists check that lookbehind ends with\n`/^$|\\n *$/` to ensure that lists only match at the beginning of a new\nline.\n\nIf this rule matches, `match` should return an object, array, or\narray-like object, which we'll call `capture`, where `capture[0]`\nis the full matched source, and any other fields can be used in the\nrule's `parse` function. The return value from `Regexp.prototype.exec`\nfits this requirement, and the common use case is to return the result\nof `someRegex.exec(source)`.\n\nIf this rule does not match, `match` should return null.\n\nNOTE: If you are using regexes in your match function, your regex\nshould always begin with `^`. Regexes without leading `^`s can\ncause unexpected output or infinite loops.\n\n#### `parse(capture, recurseParse, state)`\n\n`parse` takes the output of `match` and transforms it into a syntax\ntree node object, which we'll call `node` here.\n\n`capture` is the non-null result returned from match.\n\n`recurseParse` is a function that can be called on sub-content and\nstate to recursively parse the sub-content. This returns an array.\n\n`state` is the mutable state threading object, which can be examined\nor modified, and should be passed as the third argument to any\n`recurseParse` calls.\n\nFor example, to parse inline sub-content, you can add `inline: true`\nto state, or `inline: false` to force block parsing (to leave the\nparsing scope alone, you can just pass `state` with no modifications).\nFor example:\n\n```javascript\n    var innerText = capture[1];\n    recurseParse(innerText, _.defaults({\n        inline: true\n    }, state));\n```\n    \n`parse` should return a `node` object, which can have custom fields\nthat will be passed to `output`, below. The one reserved field is\n`type`, which designates the type of the node, which will be used\nfor output. If no type is specified, simple-markdown will use the\ncurrent rule's type (the common case). If you have multiple ways\nto parse a single element, it can be useful to have multiple rules\nthat all return nodes of the same type.\n\n#### `react(node, recurseOutput, state)`\n\n`react` takes a syntax tree `node` and transforms it into\nReact-renderable output.\n\n`node` is the return value from `parse`, which has a type\nfield of the same type as the current rule, as well as any\ncustom fields created by `parse`.\n\n`recurseOutput` is a function to recursively output sub-tree\nnodes created by using `recurseParse` in `parse`.\n\n`state` is the mutable state threading object, which can be\nexamined or modified, and should be passed as the second\nargument to any recurseOutput calls.\n\nThe simple-markdown API contains several helper methods for\ncreating rules, as well as methods for creating parsers and\noutputters from rules.\n\nExtension API\n=============\n\nsimple-markdown includes access to the default list of rules,\nas well as several functions to allow you to create parsers and\noutputters from modifications of those default rules, or even\nfrom a totally custom rule list.\n\nThese functions are separated so that you can customize\nintermediate steps in the parsing/output process, if necessary.\n\n#### `SimpleMarkdown.defaultRules`\n\nThe default rules, specified as an object, where the keys are\nthe rule types, and the values are objects containing `order`,\n`match`, `parse`, `react`, and `html` fields (these rules can\nbe used for both parsing and outputting).\n\n#### `SimpleMarkdown.parserFor(rules)`\n\nTakes a `rules` object and returns a parser for the rule types\nin the rules object, in order of increasing `order` fields,\nwhich must be present and a finite number for each rule.\nIn the case of order field ties, rules are ordered\nlexicographically by rule name. Each of the rules in the `rules`\nobject must contain a `match` and a `parse` function.\n\n#### `SimpleMarkdown.outputFor(rules, key)`\n\nTakes a `rules` object, containing a set of rules, each with an\noutput function at the `key` index (either `'react'` or `'html'`,\nunless you are custom output type), and returns an output\nfunction that takes a tree returned by the parser.\n\n#### Putting it all together\n\nGiven a set of rules, one can create a single function\nthat takes an input content string and outputs a\nReact-renderable as follows. Note that since many rules\nexpect blocks to end in `\"\\n\\n\"`, we append that to source\ninput manually, in addition to specifying `inline: false`\n(`inline: false` is technically optional for all of the\ndefault rules, which assume `inline` is false if it is\nundefined).\n\n\nExtension rules helper functions\n================================\n\n*Coming soon*\n\n\nQuirks\n======\n\nBecause of its design goals of simplicity and extensibility, simple-markdown\nhas a few quirks you may run into:\n\n### Empty lines required between blocks\n\nMany markdown parsers allow blocks to be placed on adjacent lines, as long\nas they are different types of block. For example:\n\n`````markdown\nParagraph\n```\ncode\n```\n`````\n\nrenders as `<p>Paragraph</p><pre><code>code</code></pre>`.\n\nBecause simple-markdown supports custom block syntaxes, each block element\nneeds to know for itself when it ends. So paragraphs end when they see an\nempty line, as \\`\\`\\` is not special syntax to them. To get the above to\nrender as expected in simple-markdown, you just need to have a blank line\nbetween the paragraph and code:\n\n`````markdown\nParagraph\n\n```\ncode\n```\n`````\n\nI know this is often inconvenient. It's possible to make exceptions to this\nrule via customization. For example, to make `### headings` support a new\nblock on the next line, as in issue #30, you can customize the heading rule:\n\n```javascript\nvar SimpleMarkdown = require(\"simple-markdown\");\n\nvar rules = Object.assign({}, SimpleMarkdown.defaultRules, {\n    heading: Object.assign({}, SimpleMarkdown.defaultRules.heading, {\n        match: SimpleMarkdown.blockRegex(\n            // The following regex matches:\n            // spaces,\n            // followed by 1 to 6 `#`s,\n            // followed by spaces,\n            // followed by non-newline characters,\n            // followed by optional closing `#`s,\n            // followed by optional empty lines (in defaultRules this is non-optional),\n            // followed by a final newline denoting the end of the rule\n\n            /^ *(#{1,6}) *([^\\n]+?) *#* *(?:\\n *)*\\n/\n        ),\n    }),\n});\n\nvar parser = SimpleMarkdown.parserFor(rules);\nvar reactOutput = SimpleMarkdown.outputFor(rules, 'react');\n\nvar markdownToReact = function(source) {\n    return outputReact(parse(source));\n};\n\nvar markdownToHtml = function(source) {\n    return outputHtml(parser(source));\n};\n```\n\n[nobr]: https://github.com/Benjamin-Dobell/react-native-markdown-view/pull/6\n\n\n### Outputs div html nodes instead of p html nodes\n\nBy default, simple-markdown outputs `<div class=\"paragraph\">` nodes instead\nof `p` nodes, because\n[`p` nodes cannot contain block level elements][no_div_in_p],\nwhich can lead to difficult bugs and react crashes when simple-markdown\nis customized.\n\nLike almost everything else in simple-markdown, this can be changed via\nan extension. To make simple-markdown output `p` tags, you can use:\n\n```javascript\nvar SimpleMarkdown = require(\"simple-markdown\");\n\nvar rules = Object.assign({}, SimpleMarkdown.defaultRules, {\n    paragraph: Object.assign({}, SimpleMarkdown.defaultRules.paragraph, {\n        react: (node, output, state) => {\n            return <p key={state.key}>{output(node.content, state)}</p>;\n        }\n    }),\n};\n\nvar parse = SimpleMarkdown.parserFor(rules);\nvar outputReact = SimpleMarkdown.outputFor(rules, 'react');\nvar outputHtml = SimpleMarkdown.outputFor(rules, 'html');\n\nvar markdownToReact = function(source) {\n    return outputReact(parse(source));\n};\n\nvar markdownToHtml = function(source) {\n    return outputHtml(parser(source));\n};\n```\n\n[no_div_in_p]: https://stackoverflow.com/questions/8397852/why-p-tag-cant-contain-div-tag-inside-it\n\n\nLICENSE\n=======\n\nMIT. See the LICENSE file for text.\n\n\n\nMisc.\n=====\n\nI haven't figured out where to put the following examples in the readme:\n\n### Colored Links\n\nFor example, if you wanted to make each link a different colour, you could\ndo so using `state`. We haven't covered all the concepts in this example yet,\nbut it helps demonstrate some of how `state` can provide more power to your\nparser/outputter:\n\n```javascript\n// Define an array of colours we want to use\nvar colors = ['red', 'orange', 'yellow', 'green', 'blue', 'purple'];\n\n// Define our parser/outputter's rules, basing them off\n// of SimpleMarkdown.defaultRules:\nvar rules = Object.assign({}, SimpleMarkdown.defaultRules, {\n\n    // Create a modified link rule...\n    link: Object.assign({}, SimpleMarkdown.defaultRules.link, {\n\n        // ...with a custom output function:\n        react: (node, output, state) => {\n\n            // Store the number of links we've encountered so\n            // far on the `state` object.\n            if (state.linkCount === undefined) {\n                // If this is our first link, we can start at 0\n                state.linkCount = 0;\n            } else {\n                // otherwise, we can increment our link counter\n                state.linkCount = state.linkCount + 1;\n            }\n            \n            // Calculate what colour we want this specific link to be\n            var color = colors[state.linkCount % colors.length];\n\n            // Sanitize the url for this node.\n            // (not relevant to this example, but important to do\n            // for links, so it's included here!\n            var href = SimpleMarkdown.sanitizeUrl(node.url);\n\n            // Then return the react/jsx node for this link.\n            // Note we're using the color variable from earlier for style.\n            return <a href={href} style={{color: color}}>\n                {output(node.content)}\n            </a>;\n        },\n    },\n});\n```\n","readmeFilename":"README.md","gitHead":"7aa9dc5b892d89423e53f2cd63809441d0c1dcbe","_id":"simple-markdown@1.0.0-alpha.0","_npmVersion":"5.6.0","_nodeVersion":"9.6.1","_npmUser":{"name":"ariabuckles","email":"aria@classjourney.org"},"dist":{"integrity":"sha512-SaQ6bVTEsaI23SvcqskJIe2Yozet0LoiPWDetSQ8MndKQNC9q6S/Y6jX932wjBMEy1MawilOFJPKYunUJk8rbA==","shasum":"e8cb090a9e638224d39d25004982d22ad6bd371b","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-1.0.0-alpha.0.tgz","fileCount":14,"unpackedSize":272681,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCt4pQ/nR4kbMCEbli/8Z/DhdZaERcvSQTIIWzkH5NRlgIgEqI5aoqa/vInNI8GoaEhDdytU/gYZuMKlFXfMR4D1RA="}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown_1.0.0-alpha.0_1521168949587_0.2781970179897788"},"_hasShrinkwrap":false},"0.4.0":{"name":"simple-markdown","version":"0.4.0","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test","prepublishOnly":"make minify","size":"size-limit"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Aria Buckles"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","dependencies":{},"devDependencies":{"flow-bin":"^0.71.0","flow-typed":"^2.4.0","mocha":"^5.1.1","react":"^16.3.2","react-dom":"^16.3.2","size-limit":"^0.17.0","uglify-js":"^3.3.22","underscore":"^1.9.0"},"size-limit":[{"path":"simple-markdown.js","limit":"5 KB"}],"gitHead":"b527b028688066913e5a1dd6a1bd74e2a8969407","_id":"simple-markdown@0.4.0","_npmVersion":"5.6.0","_nodeVersion":"9.11.1","_npmUser":{"name":"ariabuckles","email":"aria@classjourney.org"},"dist":{"integrity":"sha512-2PVv9vUa6k4MJpl/xdicUQEkpANTkx3R39LvQduYWFlbQiVXeuFpxzeTSWSR+SU2efqPYn/pFll5xx+2ccfrRg==","shasum":"86ec1344c7747a3ca120f5e4325be88cb4a67cc3","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.4.0.tgz","fileCount":13,"unpackedSize":248197,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJa43tICRA9TVsSAnZWagAA/SUP/0Vzw9p/dQnxKuu4253M\n0Xj+nL8CeU93p2zm4TvSGfMbLBRFjRFohjKmEFQEXf2KFmZ/5KoL11pT4GR6\nDyzfPEKlmRYfbKYiCvfmnKY5QoaQ5i8rQkhvrdYiIQbosIs+V0A+k3XzdjHi\nzCTTnsy6uHle8Tx4jRQhfnaMxpRB6rqLykAIBmkGcAJILSc4093yNCGjGEyW\nM66LzKicImJ0jNME1WMBD0RyDyVe82+Wf8WHdUbENLfKCJT7cYoCacX1/fUR\nm73HBIJrwOyzS/UjfQ3Bh8bE6gqdGjlPvqcUONgGQb2n27Fj5eMaiPRYc9aY\nj0MkCuAn3WCdOABJTNw2NejuFj7THsXfDZxCXUlCxDE306IHShhlcid9E+j/\nsFTZF3tcFmm8DNsWNFi87oTiB/sNZ+pwpinaLkHqEicAwvOE5BkZIWm0E0PD\nt7/F7HuiB9nKpGYu8OZsivfK8/1ul7tguqq21MYVmk7Qnef2TUm94KnM5mmr\n2Gf4H0EJFE9e2MYgg86aKKe0+QQ648xgR8q1uIUCF9FsbiRxXFLjkzbCF5aa\n+gMHccqHBGi5ziJfxvk1/PhhSUejQUjXogn1nVkVNR3xdAt5VnRphyBgp/QZ\nCUxICl93uUtkUJ/1oSjzHfVB7NLunjQlcK4VfhWgewdAGLUHuHVNIzFk/vco\nJh60\r\n=/Qqv\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDU6vZQSphNb8UGv0OUeihHB9w1Uk2lANeExnpU66g9hAiApVl7MUGUPzL3TNQK/0xklvX3BYjr1Ii28xEcv+b6iBw=="}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown_0.4.0_1524857670487_0.10865939024384819"},"_hasShrinkwrap":false,"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.4.1":{"name":"simple-markdown","version":"0.4.1","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test","prepublishOnly":"make minify","size":"size-limit"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Aria Buckles"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","dependencies":{},"devDependencies":{"flow-bin":"^0.71.0","flow-typed":"^2.4.0","mocha":"^5.1.1","react":"^16.3.2","react-dom":"^16.3.2","size-limit":"^0.18.0","uglify-js":"^3.3.22","underscore":"^1.9.0"},"size-limit":[{"path":"simple-markdown.js","limit":"5 KB"}],"gitHead":"91f17f71c42d5803dd0d249930ee2c6fc808df61","_id":"simple-markdown@0.4.1","_npmVersion":"6.0.1","_nodeVersion":"10.1.0","_npmUser":{"name":"ariabuckles","email":"aria@toole1.com"},"dist":{"integrity":"sha512-EkGc+efa/7qv2s9+G6sBBHPfvC6y+mq9mq0zStf8KDgHBlaRbT0U7mbA2WFUrxhUe/IDfSTilgC+G8ctc88n6A==","shasum":"dcea6afee54c964327f9c1e91b7ea22efd08cf04","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.4.1.tgz","fileCount":13,"unpackedSize":248499,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJa/KV0CRA9TVsSAnZWagAA5PsQAJc3pOFtpdTXiRFOn3Yh\nZmshodzEKdTp3GzK0M/wFda4MCmCwraRtLz3+fVIjHi/5KOITCeqMAq4kuna\n678NnqJsoCR31BsOwVHkdh9mWfR1/ju/RkIa8AR7Ni86mGWlxOMuI9IcmO88\nAt7EfghATGYhioNV4snl46+MICnuGecOtcfJlJ+0Kokg9Jm0lcyEiTl0OZim\nIGutmHHas1Xxs8F4bLmrGuFryOzA9zIvD/vmxZOFrb0vj33ejApCTXWZrECl\n7rrLTn35UPWYAFo4qs8mpvw6d0Q5IEaR9wLY8cPXpFJrFiiql1W1sXE7IWtQ\n93lx2UmGJF0GghSqProypQ3qBxD7BcaOJBwg3v7hqIdCm/4B+79NipzM/Gvo\nVz3I69iHN5MnA1xac4IvcgEQXu+DM/ucQ7Xg5HIDfGGflZqqFUPma/iTpA/L\nIeHajbyWPllbSk7jlLAeZpf4e7HbCbFa+Ng6OhxZoZRN87ARJi8MJ705fu6j\n+9Mo/pvIdBXY0laF4JG/prp58AXWnMO07rV+XkRl4iVhGd7CdW1KpUUMPFOF\ndWRC3QkX8son6Ls6jpmLt7J34JDmYIEzpzJ2HwcD+1vsRDzhVw+tQT0Nfaos\n3NhUdHNaInletekqLtBVSwsrKVJOUTgb/eOf2k/wNVBATtnS0rrBHv39XHxj\n/XTD\r\n=2tak\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQD8B9Bp3feW8SCfBeVJcXohHq2CsW1RJuCJeMw2n4fGLAIhAMr2fzWXvP59qovSJITIYSUN90t74I/LfSPplghzeoS1"}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown_0.4.1_1526506866484_0.3558952717103703"},"_hasShrinkwrap":false,"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.4.2":{"name":"simple-markdown","version":"0.4.2","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test","prepublishOnly":"make minify","size":"size-limit"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Aria Buckles"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","dependencies":{},"devDependencies":{"flow-bin":"^0.71.0","flow-typed":"^2.4.0","mocha":"^5.1.1","nyc":"^11.8.0","react":"^16.3.2","react-dom":"^16.3.2","size-limit":"^0.18.0","uglify-js":"^3.3.22","underscore":"^1.9.0"},"size-limit":[{"path":"simple-markdown.js","limit":"5 KB"}],"gitHead":"16dcd64cab2b2e5a8851a278d83f61731d1fa2f5","_id":"simple-markdown@0.4.2","_npmVersion":"6.1.0","_nodeVersion":"10.6.0","_npmUser":{"name":"ariabuckles","email":"aria@toole1.com"},"dist":{"integrity":"sha512-lysF/mIJ3Trv/QsxY5Q5XWupVLtyPH6AslxOxscWhUshQNAfHRd7ayuXHlXkXVnujHfIVa0okDw3ZGnzCroO7Q==","shasum":"98fd72bd4f8ced9705f3e72c4cb4a00261a5eca0","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.4.2.tgz","fileCount":13,"unpackedSize":250727,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbhX5CCRA9TVsSAnZWagAAsyUP/3Dly7BcNwwd0ECTyb5V\nDVe5aIqZ4qvZnzHfWvZ+ZYrgS6piixqPzJZHZ6w1ZSQrZsHHLa82VlUJnoH1\n3WkF12uIqIa/9eut/Xhap5aesjab7pMUbXf6Be4NY2IfG4kSAVvcA2hgaZDN\nln7sV28R29CaizwCXhC3OA7Ut0GfVF5Nmb228Ml6A+re7a+kJITgArIwl2qh\ne7m78kDYfm7cGxk1Fx9bvvOuIW+TMl+5n7Zf7IMFYemN17zw2FIaUxAAOmW/\nOMOj/FYvLmE1Mhq4ky+bc+TByPMDibcW6k/RBlhpm8Gm6xMTbKne7jQ+yWpw\nLlimFMYB//3cqvxEVIp6uB0Xpj/GMjDNQYgwOwAsm515KzReWZdNqnFeI/ME\nlUdsuXvvNjzK/zx+SGv4yY0PwQCqibHVbGc6opJpzd/NOTZCnC3XKAPgIUZX\nKkfQnjLfMneoKdJ+j8ZLjIxYtXvXLdxE4VXe2p0Cj9uAFVlK5QJzBOJzQnw+\n6plRQLCVaCeu1G+SS8pvf0ss3nawgEJ1auCgMUtPbV3Utgg4idREyTn0ca19\nqyIQnkF4mtY2d5sEViN22USo1rHvlOkQEmRMTrpp4KXVD9eAtUsF4jSpZWhk\nTFKhlFTheQvXEQ0HFugTld2o9SKMP1co57T/xODThuvq6JsAdVvi0m6xUIqy\nMm12\r\n=WyHq\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDPwrsajwEsBPw+roJElMUut46u/XLcBgFoY9gB+1UC4wIhAOcv027fu/8ORPKNzT/YQVLnU9Jck6Q+1XlCFs90ymaC"}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown_0.4.2_1535475265675_0.8983053013274767"},"_hasShrinkwrap":false,"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.4.3":{"name":"simple-markdown","version":"0.4.3","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test","prepublishOnly":"make minify","size":"size-limit","heroku":"node babelmark.js"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Aria Buckles"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","dependencies":{},"devDependencies":{"express":"^4.16.4","flow-bin":"^0.94.0","flow-typed":"^2.5.1","mocha":"^6.0.2","nyc":"^13.3.0","react":"^16.8.4","react-dom":"^16.8.4","size-limit":"^0.21.1","uglify-js":"^3.4.9","underscore":"^1.9.1"},"size-limit":[{"path":"simple-markdown.js","limit":"5 KB"}],"gitHead":"e63fe52e5b43a195eed9bdb45aadfacf71cfd890","_id":"simple-markdown@0.4.3","_nodeVersion":"10.15.1","_npmVersion":"6.7.0","dist":{"integrity":"sha512-UOzWNF8BN7ysodByii3t/0IzLPiyNWiXEBuQK5Je4UwA9+Bbyk396GbZWymCA4zXp89OL3FXdSlsQH/euiw6Hw==","shasum":"e496baeb1d138adfe1025a7cc4a6b45fa852baed","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.4.3.tgz","fileCount":16,"unpackedSize":243359,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJciWyqCRA9TVsSAnZWagAAK5IP+QHesWzQNQotWmgNiXFr\nHUTL32LDiQuzwIESGwCr21NR5EA5oRI9oWJfPBhI7/i+tVrd7oaMdmUuJqs3\nAI0YyMXIUgESe+VOOEp3CsMYfxXQ9BFIn/9YAW86pW+pKojf2v7fxrcZs0Fs\n5NKULxrtBwK+fkJiCyidQjRL2jXuv+GuDS2yRRnCTsnigxcEewkwE5ET5mvL\nENiovTAQ2xJYUoFHUlzlhKWFcsZRcD+q9rr6+e90aXua8qMH/Yqfwe+YbxhH\n8EGF6kgX3WobNgkXKIrGEaMAnx6cx/0AhzB9HKUJiGWaWtPPFYRsSSigZ7Qa\nwirviB6ciCOIX2ZO3gwP5vjXmM1fc3i+ige12V7+NcrolCWOi7WDioavzV3z\nDzg5Y2mp4eIhBMO6Yx0mC1C3UwBNahI6qBxx58Z1jcD+fl/AyJYOC8ZzR+HG\nmGPqj2zPMuQGgejK248lYTsPHqpiESa9Obz1RU90SbZn3c1ZgwFd0uG67zYt\nl28X/Ka0ORKNlVIhZCoLVftpkYJoIwIAUUP2ITQ0Ik/3ZKpvb+QshxaPs9ix\nNVPC2RjVGeCJCfV7lnLkuUM4FlwXcm4QRAL3rhsNSsClZjJpf0h/IcpP9nDt\nI6J6Ud4IVplBA2z2xq5EKkqLrkh5DlwPCv61RnoG0cEL2WM252ODbSkGGp2P\nSBqt\r\n=zz+a\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIBerTIyY6ICoG0PQmHiYyzVwGUy5Sjb6Y9P65dv64kUIAiBDxo8k/nFi8NVjDlyOUC9aN6NB3oM7NvCJdkWfIaic8A=="}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmUser":{"name":"ariabuckles","email":"aria@toole1.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown_0.4.3_1552510121424_0.5840489684766497"},"_hasShrinkwrap":false,"deprecated":"XSS vulnerability in untrusted link targets fixed in API-compatible v0.4.4"},"0.4.4":{"name":"simple-markdown","version":"0.4.4","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test","prepublishOnly":"make minify","size":"size-limit","heroku":"node babelmark.js"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Aria Buckles"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","dependencies":{},"devDependencies":{"express":"^4.16.4","flow-bin":"^0.94.0","flow-typed":"^2.5.1","mocha":"^6.0.2","nyc":"^13.3.0","react":"^16.8.4","react-dom":"^16.8.4","size-limit":"^0.21.1","uglify-js":"^3.4.9","underscore":"^1.9.1"},"size-limit":[{"path":"simple-markdown.js","limit":"5 KB"}],"gitHead":"e8e40487ae9438075b5bb52176182c9bf69b7b34","_id":"simple-markdown@0.4.4","_nodeVersion":"10.15.1","_npmVersion":"6.7.0","dist":{"integrity":"sha512-ZmlNUGR1KI12sPHeQ7dQY1qM5KfOgFqClNNVO8zQ9Pg6u7gHLCPFGD+VC7MCwpGDMd1uw3Bb2TfFfR8d6bB34A==","shasum":"9bd597bdd5c2f5a789e56a4dbf06427d76c3834f","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.4.4.tgz","fileCount":16,"unpackedSize":245301,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcir1mCRA9TVsSAnZWagAAcbkP/jayNKLJuN2h+TR01AhJ\nAVduxz9UlSE5L9e2qMAtlLGo5CU658LdZpc/0P0guCTmKBFU0C3zwrwaPR5I\nzXLRlmKS6fmdS6BMRQVz1kepqKiGsY/+mz2MMXtKUCS2CAOmuIssRA6xf6H5\neE5emmnYvGgjIwt2ebx40pAJ2ruMUAW6gvcMTM8MAE7FB+dUp8QkWhhBWqpR\njuSu45sOk5LgKonxamiKnZv4BtIpjNaEKvB6Z3MqIYgWotJ5oAsM8dSozLwS\nwXo525ZTVYfVPYY74F1mJd4UmWXdr/h96ZEJOMVUkrxiZHVeeTT7eyl4IXhy\nj1kzuggNr69Jkj7XUCcTSvdRTEITHfnBF8ICKsBgZJXp7zBuG+tQKrwOZejB\nVIPlg1pzyBJfUY2RPKEosTNA+JMOHLCAKmRS2IRwhR5q7bzFQ3xiugx5Nf5O\nFWKeh8UmI0CVFWa3QhA1BsxYqWBZQHY73X2T5Qmp4DZoA7fU393U/GxzDdOu\nr2bqauGzlHyppggHxHBamtFOCBjMXDmYuhJSZWDpoKBoK72/9F0laaUAjJds\nTYAadIY2s3wylFiSp0UV5A698uTIphyWSEdtIiAxHD1uycadKpKu0+3F4Uck\nHRKF3FeCHw2WAzD8zkCAQvggkAmLVYx45216l6u3jFifDvk82S8Kbb1jgEU/\nO88S\r\n=0u4Q\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCmV9hkBFeILNGXtZ2NgHimAbVm4Pdd+4ur5N8WgfW4MwIgGNjuzspIzsbSwtA7FjwhY6zampO71aAyMbWBUigKIYc="}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmUser":{"name":"ariabuckles","email":"aria@toole1.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown_0.4.4_1552596324907_0.37255066071649257"},"_hasShrinkwrap":false},"0.5.0":{"name":"simple-markdown","version":"0.5.0","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test","prepublishOnly":"make minify","size":"size-limit","heroku":"node babelmark.js"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Aria Buckles"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","dependencies":{},"devDependencies":{"express":"^4.16.4","flow-bin":"^0.94.0","flow-typed":"^2.5.1","mocha":"^6.0.2","nyc":"^13.3.0","react":"^16.8.4","react-dom":"^16.8.4","size-limit":"^0.21.1","uglify-js":"^3.4.9","underscore":"^1.9.1"},"size-limit":[{"path":"simple-markdown.js","limit":"5 KB"}],"gitHead":"96ef4eaac0842c288dacca968034e807acf3bb35","_id":"simple-markdown@0.5.0","_nodeVersion":"10.16.0","_npmVersion":"6.9.0","dist":{"integrity":"sha512-GFcVt4025mSbreUpZHK9XCavePb59qT9vCdgIV2dQpkCQHJn0xrBi9nqQjO9SXIR+nk//mHX3UV3rMvs5UlZvw==","shasum":"9792bc6496038bebc68faf8d2940201f251a46af","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.5.0.tgz","fileCount":18,"unpackedSize":248899,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdR4YJCRA9TVsSAnZWagAAarkQAI14k+3vMi8lqgxi4DX3\nIO1dGozyzz5libMJPlse58wmx/ot/9L3NPV0Wd6d/4ps0YdvFlAOCSBj8B2f\n3AVZb/VlcgryN+hi88GRmA3LpIb0MG3zIaRISnHNH4c8YZTqrkYXBgPb8gmY\nKTCBeb18rFJCINYzqcQD10QgsDutazNkM5ZWEXJGOnTCJLCKtITAiwDQdCah\nC8DbgSdGwfsjgKRbH0mZkmJlgf0V2OvirwgznmnKNnLpJxVR/5BTQdW+ivbc\nRF4JFOgZY0AKBZwVX+xUSd0CnY4EYS8gh8w8StcpH4hSpKrpdAizX8YuIbKp\n8BILTiZjm+7C2Y00+ZQYxGxJtuMmt8kaRQGO5QTFuBY5zFCYKASw4imzw/DH\nbN/sdkhEA7qlFmESx4w/KzWdhHa8SLQVkCkX9Om8IDcDX1spmjpyxBFIbxYl\n+uSFJPyRX6BBSALgMWv5uswDOso7RoxMa1JjdHPNCBy4S/MYwLDpPBeXmvCh\ngD6wEzLCk80M0n4z41KOXYMLbhs0ddGdxn2jiWka5FsZi7fizcBQjf4eyDcK\nppRKdZMrT/3bnAl/Tf/nK5D6WKC63AmUf8KK4bn850LvjE+j3ByKQbscZdnJ\nuY+Tg+gO9H4khPMHj/qZbBlX5BC8dp+aVT65wsi2ctBBOSspy9CLLiCMUue/\nMSb/\r\n=x5NQ\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICs0bKzKS7xWfZ1a1nQp7kjUbx1wetgr6CJKzUjtM2SjAiB6ffs3VMLlcXQjl1wb/AhksBNgaSAuXOnqNx8zGn9UCg=="}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmUser":{"name":"ariabuckles","email":"aria@toole1.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown_0.5.0_1564968456958_0.9082548958850531"},"_hasShrinkwrap":false},"0.5.1":{"name":"simple-markdown","version":"0.5.1","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test","prepublishOnly":"make minify","size":"size-limit","heroku":"node babelmark.js"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Aria Buckles"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","dependencies":{},"devDependencies":{"express":"^4.16.4","flow-bin":"^0.94.0","flow-typed":"^2.5.1","mocha":"^6.0.2","nyc":"^13.3.0","react":"^16.8.4","react-dom":"^16.8.4","size-limit":"^0.21.1","uglify-js":"^3.4.9","underscore":"^1.9.1"},"size-limit":[{"path":"simple-markdown.js","limit":"5 KB"}],"gitHead":"b9c05c5fbbc03d9e10c86ccd998c6024bd4d0310","_id":"simple-markdown@0.5.1","_nodeVersion":"10.16.0","_npmVersion":"6.9.0","dist":{"integrity":"sha512-sFd1OPwEq0aEk3y0KUAkD0OiakTsYDDcfqga892ZLWWy89LmpJj9ZDU2WOc+C18ej3iNgIi15xU0YKKnAQcuEQ==","shasum":"f6ac98c9df823506110f21b87283249efb35df72","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.5.1.tgz","fileCount":6,"unpackedSize":96489,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdSFfNCRA9TVsSAnZWagAAbZ0P/3JiFfCHzYFUUxkVYURI\n7V7vxpfr3ZRsuuIbrzpze1lVF5QYF8Yf1oEiqqQXu691MJ5G22VaOQmfEHwG\nwH5Ju9rciN7Tf017TIZC+8TC3wuRBZHgLNAO2NGk6EOXD2TbcV6/CpMPicTS\nvwIoK14LvmIjfpUSo3MynPrgD4RUSdQM9PTxzDckFzLKqKOXb3Ul8ofhYPqz\n2UBt5Te+x3AHwVTES58g/qskykPq9nwuoHjiraffHG6YVnTnv1uNZD0+vNUk\nLcwXIBbxh943O4k5oNhm3o02LT3nW31zM3wLqCs9mfgEJr0I4KX82onv8Pgj\nxT6ZP4+6RP4bYH16znDKBlG1MazWRiaaPPeutSTp+p04BUCsJcHCbwlpx/53\n6q6zmd5O8ZNgtUY8h924aosyaHBeq4c2TTF9+HEwmEJUL03WyUfetTpM+BzY\nr5HWYd1kpMW+vQfCVZ0pskHo0XFh1Vb27knmq42ZWn9Pn9caz0ip7wqU2/Zk\nMUXZLOBXSLYsUsJO9jwlPZzMaDdcC4OvhPUxuXCSnCLHupTezFDmKL2akng+\nUaw/cDgPgOS1lpgTtee1byx67QLCZ/lkiS3kda4HM/76qAZdQ5DIPEoHlIl4\nZhZDCXdZSH47++uaCYyXj0AXvlymo7g2KBVRTeTGzJQ9OpuHgT/zUlP7WXcw\nNQUx\r\n=1oU7\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCwpbp8CqcFo4VQG6PLv2LdNkNZeRw/SeBcT110elwovQIhAMpRA1ws8FAAbYYUZhPTCSUUTlIGn4o9+bEVW0b6Pz4l"}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmUser":{"name":"ariabuckles","email":"aria@toole1.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown_0.5.1_1565022156870_0.02907867099392214"},"_hasShrinkwrap":false},"0.5.2":{"name":"simple-markdown","version":"0.5.2","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test","prepublishOnly":"make minify","size":"size-limit","heroku":"node babelmark.js"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Aria Buckles"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","dependencies":{},"devDependencies":{"express":"^4.16.4","flow-bin":"^0.94.0","flow-typed":"^2.5.1","mocha":"^6.0.2","nyc":"^13.3.0","react":"^16.8.4","react-dom":"^16.8.4","size-limit":"^0.21.1","uglify-js":"^3.4.9","underscore":"^1.9.1"},"size-limit":[{"path":"simple-markdown.js","limit":"5 KB"}],"gitHead":"01bcc3e74e1cc095fc4a3da17687b93bfb2e0368","_id":"simple-markdown@0.5.2","_nodeVersion":"10.16.3","_npmVersion":"6.9.0","dist":{"integrity":"sha512-HtfHMkT6C+vwPoY/AmDv71GMFK5NcNYN6HhT8W3hbYOrbWDlo+EkrFhM6cCGLh9qQj+AdRvlI3dlmtK4bDIhag==","shasum":"9b5e302122f6a8e98173371d83a225f5518e3103","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.5.2.tgz","fileCount":6,"unpackedSize":96653,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdavMzCRA9TVsSAnZWagAAsxcP/0gpBpoH1cl2aVPnHCv8\nKphZSk+MNwbiOOfnsKoqTHXRrbvAMod/S/5VyJzi0I40O0/gbh7dccQsn9vn\nLC1NYwDxSiXKtabSn4NTxxVDb6rtxDSQ06dB6zZV745SVQ8SzG6SFWvakd/A\nJOHDDwqUc/hDlJM0A4g/KC9CEhC4U/r2B1he3wb4GW+CepDXG2YXPSCB7ySw\nvteF+eGqBpJRD3jwBs+DUTL42Ej5/ZLSqqLPCs+RQ9zcrKcSwWNpns9AttZe\nOY5xebG/RM2lNbipxlqsT9KN6fyU470uPF2tuaIrEMwFj9UWyJATmSKNc+gw\nFketxfbHmZGs3G+PlKv28e5GEZAFyg7rEEYNKcEFWEHKi71EZJODQSFWa0HJ\nRv1/jwccNgdYk+rA5GX261z2JlwwjCAtyg4eokcjKO/Bv/Idh5pt28IDVOvm\nNoGteYX9kp0vkGNUdtAvH6LePnHQB2+2p1u42lY2Ig4eDW5rc+xDPdMi6d9+\nMfXWJC/sgHnql4V70MWPPoCGeHZpirfCM+IvVHlgEBluIt3woAWOd+147ned\nFeMHVAjjo0wo0o1xiHQ/abHj4HulqUTDg90nDWh0uFHqoQiOpEEHvHIS0ita\njyOPyFMiZthUUNuLKtgepPtwZtiHBTsVu+btyHDevgKY0j4RGEFjgJ7gTJ32\nM40U\r\n=LjAc\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDzteKjAGZB9L4qFDrEAeiLxbtGgVH4a938sJYFd/t2RwIgHEUdcSYDCmbZ2dpeyVuHb4peP0nS7vxBW9WNRn1gGoI="}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmUser":{"name":"ariabuckles","email":"aria@toole1.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown_0.5.2_1567290162566_0.14230606844485005"},"_hasShrinkwrap":false},"0.5.3":{"name":"simple-markdown","version":"0.5.3","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test","prepublishOnly":"make minify","size":"size-limit","heroku":"node babelmark.js"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Aria Buckles"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","dependencies":{},"devDependencies":{"express":"^4.16.4","flow-bin":"^0.94.0","flow-typed":"^2.5.1","mocha":"^6.0.2","nyc":"^13.3.0","react":"^16.8.4","react-dom":"^16.8.4","size-limit":"^0.21.1","uglify-js":"^3.4.9","underscore":"^1.9.1"},"size-limit":[{"path":"simple-markdown.js","limit":"5 KB"}],"gitHead":"bdf04275a2ab44c0d73f1f5d4bd5f0ff42b9a4bd","_id":"simple-markdown@0.5.3","_nodeVersion":"10.16.3","_npmVersion":"6.9.0","dist":{"integrity":"sha512-nFvw0DTiVHdd7v/f1DyuQ+2b3V3ZXummODZ9z9IO2dBVM+h4Cg5nnfuU43h6DYcsVrHHI1HcMe8t3b/lpAYBIQ==","shasum":"4c31cc7adbadb545d9a0ba782a6f0f3ef78dbb24","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.5.3.tgz","fileCount":6,"unpackedSize":96633,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdgt0WCRA9TVsSAnZWagAA0FsP/jloryqberX4r/qlVxyq\n1E2xUm1fMS/1psC63wyRMY7wfh3tfSf3dS/MaaxLQAWEGu9XoKMm4YGKVSc+\nIz5Jf5S8tq3Cl4G5h5jR3F1g9hh7G7aJGgNj6z98fVt0FC6kgoR/0BrstybL\nzskCCz1c18gFkxrD2fiRWVFZXwBwUTNjx/CZDzOa4S4hFh/QkqAQpsU1FaLl\nOoQQzOTcSQPvFx9hcQbc6stENsUM2Sz2FB+N2OF+nZFbkhYmjlo3EkBLFFjn\n5AGJVxKG3Kk+QqfhE60YJFyYCRlagZfhf65f93ctZzTLKz9LnR29K8vd+U0/\n3EhbtAWN2cqhM+vp+9LLuBFugXS+/VjGxPwCOM0L6ZCrK3K5MnZSET0HL+PJ\nhFkf/sHgQaQXX8MDt6IqDJtYtCJRKEUajPbNOExtTFP0RFRoRlEQuPpFsiFD\n+1/r658FlrTy7flc0ADXGqkm7WtpvSqgN0H6DO8yEh6TZ7X7XG1HB3SWxDjx\nf90mXeAmJnnhzzU/MA0Xs3quZMM0YHVLTG5hk+c/g1YXZz7W67LxcqefMz6Y\n0N4Qo+384ooSxZhI7PNmpmjnb4/sW3yhHdaSDAcSlB+YRKT0zOAM3XnqayWa\nDJGUrTep9BUirfLEksj++r3odsFS5Tng0C4lR4/pO/vftxvQuHO79MhQ86Oa\n1fZa\r\n=jqHX\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICpmwYn3EjN9q5ncsp3NvVThqV4VG7NTPY9OSf+61ReWAiAHDLWESKqthIIw9EVhSFTi2VzG+RPrmlINAHY4hqh7ww=="}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmUser":{"name":"ariabuckles","email":"aria@toole1.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown_0.5.3_1568857365747_0.9279638737675298"},"_hasShrinkwrap":false},"0.6.0":{"name":"simple-markdown","version":"0.6.0","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test","prepublishOnly":"make minify","size":"size-limit","heroku":"node babelmark.js"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Aria Buckles"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","dependencies":{},"devDependencies":{"express":"^4.16.4","flow-bin":"^0.94.0","flow-typed":"^2.5.1","mocha":"^6.2.0","nyc":"^14.1.1","react":"^16.8.4","react-dom":"^16.8.4","size-limit":"^0.21.1","uglify-js":"^3.4.9","underscore":"^1.9.1"},"size-limit":[{"path":"simple-markdown.js","limit":"5 KB"}],"gitHead":"8a2b42806ca1298d56f95cba3b1ba3c7495e73ae","_id":"simple-markdown@0.6.0","_nodeVersion":"10.16.3","_npmVersion":"6.9.0","dist":{"integrity":"sha512-xZd6I4W1jtfP73hpAYwwVY7t+gQWqfZ105NP3qS/hOTtXZ9beQ2Q572Mpk+jBqoUNafgvd7XeeIx5NEOOYFz0Q==","shasum":"956e491692a22955fcbf4cf36b6f9e293b512126","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.6.0.tgz","fileCount":6,"unpackedSize":97068,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdgt00CRA9TVsSAnZWagAAcvQP/0+iglfaCm1BXW5dYBw5\nASNNTWWyB1NoYjg8IIrrK++5wVil8F288S79yRaFDqc4q0iUapAgCS8iLveu\noN8uvQC8OYH6kJI+WYyqnIMQ8IqJAYUZmQOuem6K7+IB2H0Jvsp1YphWzhuA\n/oE9R+YpWzzgvcUwRr1e2HQ8GEAwz5vcCCls078X457lP5Cn3eEv2XNyJWf5\ndBNkHcMDhj/TuFo9haXhp9SmfiSB6BZuRHurVWj35nFhdtYoTZwQfjogpcBD\nX8Chfug7drjaqbh/Yas9ouFktVRdxLSIXMip6Jr765dYoiDpmCE4+iD7dG2L\n6rXvWkmyWZIxSZQVLD4qIfDc24CuBxG4Xat41Qmy3aaY7gTaq3gAzgT/QXNA\n9MevVPuN5BmOc0DRrOtCaN0WcnsG17iUoTi6d2kWi9wpThp/SCDW1lFESkI3\nq4aLcYskCJM/y3JrJcVhMmU0vysDnjRsBL3WfztQ5rJKhkHyuf/bl8HfPp3C\nTSKw+xVwk74ryJzZ/q7t60xQum1bjSoiIT98bU379dDpViVNONkJzkvQM6Aj\nR0X3JiIXxLeyfjh8CQQk9zkoj+JAI3I/OWxTx0PK7JuaLuDmyQ0fwC+lOnD9\nIcaI7VkccRa/fr0QGnUcDqVP3kuNVwoBUyx87XEsQxnzwjsvtDf8ys81wF8c\nsnZn\r\n=H7Bk\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDrL5CtwGbdyE3oJ+VYGKHLKKcZCfhf6Ks0I6qtrKwtNwIhAMZRXKzLUOL0D/MlztY1k/enc2CxyTcAg+8PGwqr1pVg"}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmUser":{"name":"ariabuckles","email":"aria@toole1.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown_0.6.0_1568857395628_0.4696538771667891"},"_hasShrinkwrap":false},"0.6.1":{"name":"simple-markdown","version":"0.6.1","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","scripts":{"test":"make test","prepublishOnly":"make minify","size":"size-limit","heroku":"node babelmark.js"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing"],"author":{"name":"Aria Buckles"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","dependencies":{},"devDependencies":{"express":"^4.16.4","flow-bin":"^0.94.0","flow-typed":"^2.5.1","mocha":"^6.2.0","nyc":"^14.1.1","react":"^16.8.4","react-dom":"^16.8.4","size-limit":"^0.21.1","uglify-js":"^3.4.9","underscore":"^1.9.1"},"size-limit":[{"path":"simple-markdown.js","limit":"5 KB"}],"gitHead":"a6308532fca87154528bf27af4dec5fd2ad3024f","_id":"simple-markdown@0.6.1","_nodeVersion":"10.16.3","_npmVersion":"6.9.0","dist":{"integrity":"sha512-02HKXvM9J7pJWf74fuWthcgof5jF81Yndt+XcXtWnEtpp8QaX9dUAJpdAA6KWrB/rSGzrOi0PRAVy9/0bJiIZw==","shasum":"220e5eb45bc57b3809a380bc89f77f71de93bb33","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.6.1.tgz","fileCount":6,"unpackedSize":97070,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdsjFBCRA9TVsSAnZWagAAWgEP/1GyJU63qO9ZpGbIhsPI\n1+P+99D0hazRBGcWnNcB3nWeYmgpXB0tL5b/gIwNW5xqx9kddXkeLhwRlx8H\n9fkb435YpidDE4QSrALvx/N3kZ0l7NpcXOkYEmEz2VbQecoZdgQp7c3wSCUT\nxYpMfsrvAF8HK0JlsM/F+9Ueh1HqXqioHImi79xktQyL/bbDOOJ/YGY5Un2f\naSx9ADJBa9815bdzdc+L1kM1rAzKywg9TVjCkZCSG/+dYgK6TlsT/EO93ThK\nvOLd4Wb9kIdMTCpNzupfOzo+B5M/uvZPRyDEy2ZUldjlubKLV5QXbgiISCaf\n4HAg4zzn9MkdFX7WHhWka4xE1PO6ESRFy3gE2EehwP8BqNXWL7h0uPJG8yAj\n/tzVAuYItfYuNZWkTtdKu/6AQbWA4KvmjvA7Zxm6qN69o7jI+s8Zsa2aoLqU\nJx+fYbJAqv1VKXQQzrjWXNM/BpY0cgSMpB4usTWFdPQ3Z2+Uuqg4AuDywr9Y\n6y5FRr4nxPkHs7fAtvjzRhyLEsbkZqJnoA87H2kkF/ENMrsOELJBk/cYkPo/\ni1zyzrI19y5kXVb8C2YBiZ+af9G68AqRDua9BbUZ4Ro+SM5kh/K6lZ2tJGWt\npkY64wB3MeziJwsBdA96kqrAFki7+6P0Cer7Yi7CtX/5LKjMvJW1Y/Joc8Fj\nRTol\r\n=7w27\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDbwTrqbz4BAJxmvuIyGlEJ8ZOowDFlgkPRdbBK37bJoQIgcu+vRiy/WN71+DpEDXu+f/l2Lg7HnwYwa6w8zCyZjfw="}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmUser":{"name":"ariabuckles","email":"aria@toole1.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown_0.6.1_1571959104974_0.2958067479088706"},"_hasShrinkwrap":false},"0.7.0":{"name":"simple-markdown","version":"0.7.0","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","types":"simple-markdown.d.ts","scripts":{"test":"make test","prepublishOnly":"make minify","size":"size-limit","heroku":"node babelmark.js"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing","extension","flow","typescript"],"author":{"name":"Aria Buckles"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","dependencies":{"@types/node":">=10.0.0","@types/react":">=16.0.0"},"devDependencies":{"@types/mocha":"^5.2.7","@types/react-dom":">=16.0.0","@types/underscore":">=1.4.4","express":"^4.16.4","flow-bin":"^0.94.0","flow-typed":"^2.5.1","mocha":"^6.2.0","nyc":"^14.1.1","react":"^16.8.4","react-dom":"^16.8.4","size-limit":"^0.21.1","typescript":"^3.6.4","uglify-js":"^3.4.9","underscore":"^1.9.1"},"size-limit":[{"path":"simple-markdown.js","limit":"5 KB"}],"readme":"simple-markdown\n===============\n\nsimple-markdown is a markdown-like parser designed for simplicity\nand extensibility.\n\n[Change log](https://github.com/Khan/simple-markdown/releases)\n\nPhilosophy\n----------\n\nMost markdown-like parsers aim for [speed][marked] or\n[edge case handling][CommonMark].\nsimple-markdown aims for extensibility and simplicity.\n\n[marked]: https://github.com/chjj/marked\n[CommonMark]: https://github.com/jgm/CommonMark\n\nWhat does this mean?\nMany websites using markdown-like languages have custom extensions,\nsuch as `@`mentions or issue number linking. Unfortunately, most\nmarkdown-like parsers don't allow extension without\nforking, and can be difficult to modify even when forked.\nsimple-markdown is designed to allow simple addition of\ncustom extensions without needing to be forked.\n\nAt Khan Academy, we use simple-markdown to format\nover half of our math exercises, because we need\n[markdown extensions][PerseusMarkdown] for math text and\ninteractive widgets.\n\n[PerseusMarkdown]: https://github.com/Khan/perseus/blob/master/src/perseus-markdown.jsx\n\nsimple-markdown is [MIT licensed][LICENSE].\n\n[LICENSE]: https://github.com/Khan/simple-markdown/blob/master/LICENSE\n\nGetting started\n---------------\n\nFirst, let's parse and output some generic markdown using\nsimple-markdown.\n\nIf you want to run these examples in\nnode, you should run `npm install` in the simple-markdown\nfolder or `npm install simple-markdown` in your project's\nfolder. Then you can acquire the `SimpleMarkdown` variable\nwith:\n\n```javascript\n    var SimpleMarkdown = require(\"simple-markdown\");\n```\n\nThen let's get a basic markdown parser and outputter.\n`SimpleMarkdown` provides default parsers/outputters for\ngeneric markdown:\n\n```javascript\n    var mdParse = SimpleMarkdown.defaultBlockParse;\n    var mdOutput = SimpleMarkdown.defaultOutput;\n```\n\n`mdParse` can give us a syntax tree:\n\n```javascript\n    var syntaxTree = mdParse(\"Here is a paragraph and an *em tag*.\");\n```\n\nLet's inspect our syntax tree:\n\n```javascript\n    // pretty-print this with 4-space indentation:\n    console.log(JSON.stringify(syntaxTree, null, 4));\n    => [\n        {\n            \"content\": [\n                {\n                    \"content\": \"Here is a paragraph and an \",\n                    \"type\": \"text\"\n                },\n                {\n                    \"content\": [\n                        {\n                            \"content\": \"em tag\",\n                            \"type\": \"text\"\n                        }\n                    ],\n                    \"type\": \"em\"\n                },\n                {\n                    \"content\": \".\",\n                    \"type\": \"text\"\n                }\n            ],\n            \"type\": \"paragraph\"\n        }\n    ]\n```\n\nThen to turn that into an array of React elements, we can\ncall `mdOutput`:\n\n```javascript\n    mdOutput(syntaxTree)\n    => [ { type: 'div',\n        key: null,\n        ref: null,\n        _owner: null,\n        _context: {},\n        _store: { validated: false, props: [Object] } } ]\n```\n\n\nAdding a simple extension\n-------------------------\n\nLet's add an underline extension! To do this, we'll need to create\na new rule and then make a new parser/outputter. The next section\nwill explain how all of these steps work in greater detail. (To\nfollow along with these examples, you'll also need\n[underscore][underscore].)\n\n[underscore]: http://underscorejs.org/\n\nFirst, we create a new rule. We'll look for double underscores\nsurrounding text.\n\nWe'll put underlines right\nbefore `em`s, so that `__` will be parsed before `_`\nfor emphasis/italics.\n\nA regex to capture this would look something\nlike `/^__([\\s\\S]+?)__(?!_)/`. This matches `__`, followed by\nany content until it finds another `__` not followed by a\nthird `_`.\n\n```javascript\n    var underlineRule = {\n        // Specify the order in which this rule is to be run\n        order: SimpleMarkdown.defaultRules.em.order - 0.5,\n        \n        // First we check whether a string matches\n        match: function(source) {\n            return /^__([\\s\\S]+?)__(?!_)/.exec(source);\n        },\n        \n        // Then parse this string into a syntax node\n        parse: function(capture, parse, state) {\n            return {\n                content: parse(capture[1], state)\n            };\n        },\n        \n        // Finally transform this syntax node into a\n        // React element\n        react: function(node, output) {\n            return React.DOM.u(null, output(node.content));\n        },\n\n        // Or an html element:\n        // (Note: you may only need to make one of `react:` or\n        // `html:`, as long as you never ask for an outputter\n        // for the other type.)\n        html: function(node, output) {\n            return '<u>' + output(node.content) + '</u>';\n        },\n    };\n```\n\nThen, we need to add this rule to the other rules:\n\n```javascript\n    var rules = _.extend({}, SimpleMarkdown.defaultRules, {\n        underline: underlineRule\n    });\n```\n\nFinally, we need to build our parser and outputters:\n\n```javascript\n    var rawBuiltParser = SimpleMarkdown.parserFor(rules);\n    var parse = function(source) {\n        var blockSource = source + \"\\n\\n\";\n        return rawBuiltParser(blockSource, {inline: false});\n    };\n    // You probably only need one of these: choose depending on\n    // whether you want react nodes or an html string:\n    var reactOutput = SimpleMarkdown.reactFor(SimpleMarkdown.ruleOutput(rules, 'react'));\n    var htmlOutput = SimpleMarkdown.htmlFor(SimpleMarkdown.ruleOutput(rules, 'html'));\n```\n\nNow we can use our custom `parse` and `output` functions to parse\nmarkdown with underlines!\n\n```javascript\n    var syntaxTree = parse(\"__hello underlines__\");\n    console.log(JSON.stringify(syntaxTree, null, 4));\n    => [\n        {\n            \"content\": [\n                {\n                    \"content\": [\n                        {\n                            \"content\": \"hello underlines\",\n                            \"type\": \"text\"\n                        }\n                    ],\n                    \"type\": \"underline\"\n                }\n            ],\n            \"type\": \"paragraph\"\n        }\n    ]\n    \n    reactOutput(syntaxTree)\n    => [ { type: 'div',\n        key: null,\n        ref: null,\n        _owner: null,\n        _context: {},\n        _store: { validated: false, props: [Object] } } ]\n\n    htmlOutput(syntaxTree)\n\n    => '<div class=\"paragraph\"><u>hello underlines</u></div>'\n```\n\n\nBasic parsing/output API\n------------------------\n\n#### `SimpleMarkdown.defaultBlockParse(source)`\n\nReturns a syntax tree of the result of parsing `source` with the\ndefault markdown rules. Assumes a block scope.\n\n#### `SimpleMarkdown.defaultInlineParse(source)`\n\nReturns a syntax tree of the result of parsing `source` with the\ndefault markdown rules, where `source` is assumed to be inline text.\nDoes not emit `<p>` elements. Useful for allowing inline markdown\nformatting in one-line fields where paragraphs, lists, etc. are\ndisallowed.\n\n#### `SimpleMarkdown.defaultImplicitParse(source)`\n\nParses `source` as block if it ends with `\\n\\n`, or inline if not.\n\n#### `SimpleMarkdown.defaultOutput(syntaxTree)`\n\nReturns React-renderable output for `syntaxTree`.\n\n*Note: raw html output will be coming soon*\n\n\nExtension Overview\n------------------\n\nElements in simple-markdown are generally created from rules.\nFor parsing, rules must specify `match` and `parse` methods.\nFor output, rules must specify a `react` or `html` method\n(or both), depending on which outputter you create afterwards.\n\nHere is an example rule, a slightly modified version of what\nsimple-markdown uses for parsing **strong** (**bold**) text:\n\n```javascript\n    strong: {\n        match: function(source, state, lookbehind) {\n            return /^\\*\\*([\\s\\S]+?)\\*\\*(?!\\*)/.exec(source);\n        },\n        parse: function(capture, recurseParse, state) {\n            return {\n                content: recurseParse(capture[1], state)\n            };\n        },\n        react: function(node, recurseOutput) {\n            return React.DOM.strong(null, recurseOutput(node.content));\n        },\n        html: function(node, recurseOutput) {\n            return '<strong>' + recurseOutput(node.content) + '</strong>';\n        },\n    },\n```\n\nLet's look at those three methods in more detail.\n\n#### `match(source, state, lookbehind)`\n\nsimple-markdown calls your `match` function to determine whether the\nupcoming markdown source matches this rule or not.\n\n`source` is the upcoming source, beginning at the current position of\nparsing (source[0] is the next character).\n\n`state` is a mutable state object to allow for more complicated matching\nand parsing. The most common field on `state` is `inline`, which all of\nthe default rules set to true when we are in an inline scope, and false\nor undefined when we are in a block scope.\n\n**DEPRECATED - use `state.prevCapture` instead.** `lookbehind` is the string previously captured at this parsing level, to\nallow for lookbehind. For example, lists check that lookbehind ends with\n`/^$|\\n *$/` to ensure that lists only match at the beginning of a new\nline.\n\nIf this rule matches, `match` should return an object, array, or\narray-like object, which we'll call `capture`, where `capture[0]`\nis the full matched source, and any other fields can be used in the\nrule's `parse` function. The return value from `Regexp.prototype.exec`\nfits this requirement, and the common use case is to return the result\nof `someRegex.exec(source)`.\n\nIf this rule does not match, `match` should return null.\n\nNOTE: If you are using regexes in your match function, your regex\nshould always begin with `^`. Regexes without leading `^`s can\ncause unexpected output or infinite loops.\n\n#### `parse(capture, recurseParse, state)`\n\n`parse` takes the output of `match` and transforms it into a syntax\ntree node object, which we'll call `node` here.\n\n`capture` is the non-null result returned from match.\n\n`recurseParse` is a function that can be called on sub-content and\nstate to recursively parse the sub-content. This returns an array.\n\n`state` is the mutable state threading object, which can be examined\nor modified, and should be passed as the third argument to any\n`recurseParse` calls.\n\nFor example, to parse inline sub-content, you can add `inline: true`\nto state, or `inline: false` to force block parsing (to leave the\nparsing scope alone, you can just pass `state` with no modifications).\nFor example:\n\n```javascript\n    var innerText = capture[1];\n    recurseParse(innerText, _.defaults({\n        inline: true\n    }, state));\n```\n    \n`parse` should return a `node` object, which can have custom fields\nthat will be passed to `output`, below. The one reserved field is\n`type`, which designates the type of the node, which will be used\nfor output. If no type is specified, simple-markdown will use the\ncurrent rule's type (the common case). If you have multiple ways\nto parse a single element, it can be useful to have multiple rules\nthat all return nodes of the same type.\n\n#### `react(node, recurseOutput, state)`\n\n`react` takes a syntax tree `node` and transforms it into\nReact-renderable output.\n\n`node` is the return value from `parse`, which has a type\nfield of the same type as the current rule, as well as any\ncustom fields created by `parse`.\n\n`recurseOutput` is a function to recursively output sub-tree\nnodes created by using `recurseParse` in `parse`.\n\n`state` is the mutable state threading object, which can be\nexamined or modified, and should be passed as the second\nargument to any recurseOutput calls.\n\nThe simple-markdown API contains several helper methods for\ncreating rules, as well as methods for creating parsers and\noutputters from rules.\n\nExtension API\n-------------\n\nsimple-markdown includes access to the default list of rules,\nas well as several functions to allow you to create parsers and\noutputters from modifications of those default rules, or even\nfrom a totally custom rule list.\n\nThese functions are separated so that you can customize\nintermediate steps in the parsing/output process, if necessary.\n\n#### `SimpleMarkdown.defaultRules`\n\nThe default rules, specified as an object, where the keys are\nthe rule types, and the values are objects containing `order`,\n`match`, `parse`, `react`, and `html` fields (these rules can\nbe used for both parsing and outputting).\n\n#### `SimpleMarkdown.parserFor(rules)`\n\nTakes a `rules` object and returns a parser for the rule types\nin the rules object, in order of increasing `order` fields,\nwhich must be present and a finite number for each rule.\nIn the case of order field ties, rules are ordered\nlexicographically by rule name. Each of the rules in the `rules`\nobject must contain a `match` and a `parse` function.\n\n#### `SimpleMarkdown.ruleOutput(rules, key)`\n\nTakes a `rules` object, containing an `output` function for\neach rule, and a `key` into individual elements in that rules\nrules argument (either `'react'` or `'html'`, unless you are\ndefining a custom output type), and returns a function that can\noutput a single syntax tree node of any type that is in the\n`rules` object, given a node and a recursive output function.\nThis is not the final output function because it doesn't handle\narrays of nodes or recursion (see `reactFor` and `htmlFor`).\n\n#### `SimpleMarkdown.reactFor(singleNodeOutputFunction)`\n\nTakes a function that can output react-renderable output for\nany single syntax tree node and returns a function that maps\nover syntax tree arrays correctly.\n\nThe most common use case is to pass the output of\n`ruleOutput` as the parameter to `reactFor`:\n\n```javascript\n    var output = SimpleMarkdown.reactFor(SimpleMarkdown.ruleOutput(rules, 'react'));\n```\n\n#### `SimpleMarkdown.htmlFor(singleNodeOutputFunction)`\n\nTakes a function that can output an html string for\nany single syntax tree node and returns a function that maps\nover syntax tree arrays correctly.\n\nThe most common use case is to pass the output of\n`ruleOutput` as the parameter to `htmlFor`:\n\n```javascript\n    var output = SimpleMarkdown.htmlFor(SimpleMarkdown.ruleOutput(rules, 'html'));\n```\n\n#### Putting it all together\n\nGiven a set of rules, one can create a single function\nthat takes an input content string and outputs a\nReact-renderable as follows. Note that since many rules\nexpect blocks to end in `\"\\n\\n\"`, we append that to source\ninput manually, in addition to specifying `inline: false`\n(`inline: false` is technically optional for all of the\ndefault rules, which assume `inline` is false if it is\nundefined).\n\n```javascript\nvar rules = {\n    ...SimpleMarkdown.defaultRules,\n    paragraph: {\n        ...SimpleMarkdown.defaultRules.paragraph,\n        react: (node, output, state) => {\n            return <p key={state.key}>{output(node.content, state)}</p>;\n        }\n    }\n};\n\nvar parser = SimpleMarkdown.parserFor(rules);\nvar reactOutput = SimpleMarkdown.reactFor(SimpleMarkdown.ruleOutput(rules, 'react'));\nvar htmlOutput = SimpleMarkdown.reactFor(SimpleMarkdown.ruleOutput(rules, 'html'));\n\nvar blockParseAndOutput = function(source) {\n    // Many rules require content to end in \\n\\n to be interpreted\n    // as a block.\n    var blockSource = source + \"\\n\\n\";\n    var parseTree = parser(blockSource, {inline: false});\n    var outputResult = htmlOutput(parseTree);\n    // Or for react output, use:\n    // var outputResult = reactOutput(parseTree);\n    return outputResult;\n};\n```\n\nExtension rules helper functions\n--------------------------------\n\n*Coming soon*\n\nLICENSE\n-------\nMIT. See the LICENSE file for text.\n","readmeFilename":"README.md","gitHead":"c1e7ce469287e0e96b37d653946f6aed9efe4165","_id":"simple-markdown@0.7.0","_nodeVersion":"10.16.3","_npmVersion":"6.9.0","dist":{"integrity":"sha512-B6HF1jMPBoDFeZ+BhHJnrQGpJCCQxp/1fDDD7sp1SEtwIXhWUZ8+ZbOUruPwmorzlEzv7QtbpAoCbrzVFa8ZZA==","shasum":"7945033cdd1b0ef91d8136327e80aeb550f26e3c","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.7.0.tgz","fileCount":7,"unpackedSize":112839,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdsjO5CRA9TVsSAnZWagAAPMcP/3+gp5MOipVqc5JolsXZ\nHi6i0Qtb0XQfRDxLuqsCg32J1eghTp3oI4ZNuzlskE8i56ryHFtrT+V5+wxj\n3zr4Lk8iG/DsaERGT6YJnPu+qai09FFvqIGL37aC7VmC7BXUTSKm1/UXAcxg\nczO1G0ta0KsVjjQzyFvYBSeG16fZ5cJPiVLLNyLd6uhCGftf8JVtlrRYSgtP\nytUW7ybtuH+xxnWn+0CboU4JA/jMCaj2nLT+JFyekiKKpDn30ifNPkBdnsqB\naO+5HkLEcN67kbQllln7oC4WH7Lolq8ljMj1RS+4iLF3KaoNDDA8pE4AbpdZ\nczUOQQ+NRwonJ3kNbjkyV6AkNTXC77wMGdO3+b6C41ZeqCSKjLUkpaQDhaSz\n8juIcY3SwMLkQenSUv2ZeqIau3wOIwXhvWnJImXKwwFbtdIJeFHLjGWWdZdP\nlvYfJVZwWYbP+0IRLA17jKFx8o1nXUfp/+tW0ZY8F9GFBMO4HU5xaD1H/J9H\n/JglJMHX98lXPHDK2ec4s5aE3zWbzFuqY5wFN6qzoQzzZOB/xX/7EaSw7mr4\nhQAE+aD8IXvVt/LlTuamJK/4dGT5ktjNtN7bFAA0QCq+mTevIGqzNS/RlNbI\nqbHWv/yogrtbI0BmiaunvZqgXDhc420ILrbvBfOIbFBLb5ld3GdVGmFRaK/4\neSeb\r\n=Ncgz\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQC+Pnc8rVyeGsWuz6z6YPTBfxFymnhke7TgAqfekF4O2QIhAM5KTGAGfZNwMkX+sH3xPxk0gz1C2W9yqxwtWRN+r68E"}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmUser":{"name":"ariabuckles","email":"aria@toole1.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown_0.7.0_1571959736869_0.9967692773397925"},"_hasShrinkwrap":false},"0.7.1":{"name":"simple-markdown","version":"0.7.1","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","types":"simple-markdown.d.ts","scripts":{"build":"make build","test":"make test","prepublishOnly":"make build","size":"size-limit","heroku":"node babelmark.js"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing","extension","flow","typescript"],"author":{"name":"Aria Buckles"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","dependencies":{"@types/node":">=10.0.0","@types/react":">=16.0.0"},"devDependencies":{"@types/mocha":"^5.2.7","@types/react-dom":">=16.0.0","express":"^4.17.1","flow-bin":"^0.111.1","flow-typed":"^2.6.2","mocha":"^6.2.2","nyc":"^14.1.1","react":"^16.11.0","react-dom":"^16.11.0","rollup":"^1.26.3","size-limit":"^0.21.1","typescript":"^3.6.4","uglify-js":"^3.6.7"},"size-limit":[{"path":"simple-markdown.js","limit":"5 KB"}],"gitHead":"5bed44add73d3f6b086ce61960c3640607a4f492","_id":"simple-markdown@0.7.1","_nodeVersion":"10.17.0","_npmVersion":"6.11.3","dist":{"integrity":"sha512-9p92kPFjaDER1yuDgVW1UzFVQoL46HBonniqOLKnCmqn0vlxKkHIxRODBJdHLplo44tOtmnGxPTbUZ1HpYkHyg==","shasum":"48f2f65ad9f7faa5922347e9ab6baf66ab3195bc","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.7.1.tgz","fileCount":7,"unpackedSize":112464,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdv27ACRA9TVsSAnZWagAAnVgP/ibaT4cxuMkPWUNQiowt\nbsvYuDUN+hxsZgKa1yS/7krcHJTbqmS7ipwTt5dKR43Qdf2QcCSTCvz+7tFj\nPwQj+xpAnGwMNAr2X3+gsIrQxeiBl7UhrX2WmaEk7UHnsDAduoTh1c0+yoc9\nKIZs0Wrx6TX7qMA6Fl/Y3xpjX1H2N3K8B2zCFFM9YUX5VpGwQOscaVfltU5W\nGQOmH3cYWHGXgO9VxbAnRWquSoSKR9HGH3Cf9gTEUJSLy4ZHr1mJNXhQBEKK\ndZ8l8Zt3t1mpMfXZg/77dfRQhB3092GvXRPcz61x+JzU94eJZV8TaQjS59ic\nWHbIA9T4VxLdnByvOX8ijh80tiZ/HVTb6+gBZNRZVFz1endvIfoaZwwQHlDY\nZAOCjGqRCVcwEm0aSLAlT8zttG1hx8zCEr0QHG4yrQW99I/FKd/+lkNjAvjN\nkGdhHb7CEtcVRGy4DQW9oEvO4nA5PBCxoMBK3hTwSik0ovlZ2tFHzHdI7UDt\nidE1dnOgGxGEfVICjDWnB6q+jfVJGQgfwDuYowUAdJSn9TyP455Fn+AeoVv6\nFju6Fz9FeKkyIOKu/X88atVgMtQb1AYbJG791bT7gMZDPBQ+cHiJaCoEUdqL\n+U3/0hjiQctpeLASdTajxNg6jZKsNtjtz4F0vDtBKCl72H/sqWEKMZFEBLZk\npWO4\r\n=OYZx\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIAhLalJNUIJ0jm9cr3lhtCxBYJKcM8L5PB3tsW0NBrxPAiA3jyz3p3e+JVTMizAK0BIj6gDYZaORFf1iCE5KuT+eUw=="}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmUser":{"name":"ariabuckles","email":"aria@toole1.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown_0.7.1_1572826815705_0.04321686591465057"},"_hasShrinkwrap":false},"0.7.2":{"name":"simple-markdown","version":"0.7.2","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","types":"simple-markdown.d.ts","scripts":{"build":"make build","test":"make test","prepublishOnly":"make build","size":"size-limit","heroku":"node babelmark.js"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing","extension","flow","typescript"],"author":{"name":"Aria Buckles"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","dependencies":{"@types/react":">=16.0.0"},"devDependencies":{"@types/mocha":"^5.2.7","@types/react-dom":">=16.0.0","express":"^4.17.1","flow-bin":"^0.111.1","flow-typed":"^2.6.2","mocha":"^6.2.2","nyc":"^15.0.0","react":"^16.11.0","react-dom":"^16.11.0","rollup":"^1.26.3","size-limit":"^0.21.1","typescript":"^3.6.4","uglify-js":"^3.6.7"},"size-limit":[{"path":"simple-markdown.js","limit":"5 KB"}],"gitHead":"7931523bdf4fca1f3faba3280053a0987cb2f7cb","_id":"simple-markdown@0.7.2","_nodeVersion":"10.17.0","_npmVersion":"6.11.3","dist":{"integrity":"sha512-XfCvqqzMyzRj4L7eIxJgGaQ2Gaxr20GhTFMB+1yuY8q3xffjzmOg4Q5tC0kcaJPV42NNUHCQDaRK6jzi3/RhrA==","shasum":"896cc3e3dd9acd068d30e696bce70b0b97655665","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.7.2.tgz","fileCount":7,"unpackedSize":112433,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeCnNtCRA9TVsSAnZWagAAYV4QAJbe35U9Nnin7hWnSwN4\njRTN7dioCsCHbs81BfKqglvb6SOyaSOtRbHGDv3GzGauhnVf9DDcehTzBwKj\nysfFJqL3pxzuUHbg2J64OW2KSVv/gCzuxyrMmLfSe3vNpuIzOZzCEFF4AUWE\n9PqGO6wcyjYkXPcaw9M7J2hVfFM7Lymu4TdtEyoKDFVur67w3Uy9ECe3AhRv\naSZzzWKBBW4pAjinnPVmJo53z7EWj+kY7S2ZRhpqMO0UZaS5qjseDswR1pth\ngtK//nutnX4CnCsjAjtyH37KDsKrZwfvVogIOuzMQQOzbrsOlY/ShYWZ4s7e\ngkB5y89imEfIzjjYJ0dTKyi7HpSX8BXSMvMACANh8yauNdWt87/GvFu8Z5GF\nH0oXEXh6yG88CQY1NbZxmjdT3D/Ftu4QUo0cqC3DGbvuKQ1XHjjLn3RBEYes\nnMEWJjCOteUL62uytbHyYT6ok1FSCtE+KHkz2fq4BvJR72adad+la27qnQUL\n6s26Ry7t5bM9xf46diu3czqEradHqVyTNBjKbP0tVHZPBlsEYgn5na6giB3l\nAJvDcwNTPVOXsabfOz8X95OGNZG/p9MT8jeWJx5gYrag1xIiTw+iyAs3y71l\nZxgGCfmMhg+NsndGTPlgh/5bj0YpXlRf9TsQoNkMRClGDdACe2m/cr9J7OKX\nzZAL\r\n=dW9V\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCX7WuJ6ngSsIKH/0rrWPx1e+PAVQ8vaoQwpWbLWRIPewIhAKJN6Z7bu39daUiLeMtz2fdYtayWJfgxjqDlqxjdM9LM"}]},"maintainers":[{"name":"ariabuckles","email":"aria@magoosh.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"},{"name":"xymostech","email":"xymostech@gmail.com"}],"_npmUser":{"name":"ariabuckles","email":"aria@toole1.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown_0.7.2_1577743213397_0.24155083233978392"},"_hasShrinkwrap":false},"0.7.3":{"name":"simple-markdown","version":"0.7.3","description":"Javascript markdown parsing, made simple","main":"simple-markdown.js","types":"simple-markdown.d.ts","scripts":{"build":"make build","test":"make test","prepublishOnly":"make build","size":"size-limit","heroku":"node babelmark.js"},"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"keywords":["markdown","simple","react","html","ast","markup","text processing","extension","flow","typescript"],"author":{"name":"Aria Buckles"},"license":"MIT","bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"homepage":"https://github.com/Khan/simple-markdown","dependencies":{"@types/react":">=16.0.0"},"devDependencies":{"@types/mocha":"^5.2.7","@types/react-dom":">=16.0.0","express":"^4.17.1","flow-bin":"^0.111.1","flow-typed":"^2.6.2","mocha":"^6.2.2","nyc":"^15.0.0","react":"^16.11.0","react-dom":"^16.11.0","rollup":"^1.26.3","size-limit":"^0.21.1","typescript":"^3.6.4","uglify-js":"^3.6.7"},"size-limit":[{"path":"simple-markdown.js","limit":"5 KB"}],"gitHead":"f5bfed64a68d2689ee9137f35679b8b6b31193b7","_id":"simple-markdown@0.7.3","_nodeVersion":"14.15.3","_npmVersion":"6.14.9","dist":{"integrity":"sha512-uGXIc13NGpqfPeFJIt/7SHHxd6HekEJYtsdoCM06mEBPL9fQH/pSD7LRM6PZ7CKchpSvxKL4tvwMamqAaNDAyg==","shasum":"e32150b2ec6f8287197d09869fd928747a9c5640","tarball":"https://registry.npmjs.org/simple-markdown/-/simple-markdown-0.7.3.tgz","fileCount":7,"unpackedSize":112437,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJf99AbCRA9TVsSAnZWagAA6BMQAIDOdGB5p6Xd8baH/xGU\nVJfUtPj/NzUgtPfp85atK49CJ+Sr8JpeFgjEwxPdeXfVXjDChjEP7k0grini\nThlKvkPn6XV3V8mLhBRFxmPYP+voKYzjMQvzKYHanCjCUBH6QFsIcdUGXLk5\ndfkUpojWkJOfbWRagmmGlP3ud8c2u2Xt/IOI3clkKbQ4dExjR2LxELYndgGS\nzfbY87qEoXITLzYN1CgHxR6xX5OWfM/wvv8s37HwXA2lUBhoMRvnKq9y/cHt\nrMfq7Ldx26w/rjs56Gh190xjj/gmW2isW9MVrf5uDFgDjH2cnq4xwV+D7squ\nMJ3MSset8DWWCXODz6xwVzzNGHma4fpf89pI9MD/9GF6qlvhOFI48fsd2KPk\nrGGCC57us7YBv6iae7hzWd0KPt+/dEMyTi/uEqAe4O/1f5YEEpcmVHtC123H\nli0aF8OxJrAXwoGoFfu96N8BuAxbZIinYUQ1KiSwI303TRm24/N5ExqCButX\n4hAwm7p3/tKsGp3FoXXEM+aPMC0+Zym38gLmT0P5jWg99vRRgiGWJrA63gIK\nnJ4eV9kQJECcN+DbqT/IEuV+IqEA0oQrbwff745yc8taL/qm/xpgLy2YXuv9\nkI6qiQWAzhEPlvdWKehDA8Lz+73VMmlNewbiDWZV9xGLazZ0FazS4NEMVBZS\nTir3\r\n=DkUb\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDEkaV+y57UHbU4QDLGPTa28VE+KIG/VrR6jPwU8414IQIgLoja0Ng1bMZQcKxb79LCvkM/Xl7TVrw3BfCMUDEeux8="}]},"_npmUser":{"name":"ariabuckles","email":"aria@toole1.com"},"directories":{},"maintainers":[{"name":"xymostech","email":"xymostech@gmail.com"},{"name":"ariabuckles","email":"aria@toole1.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-markdown_0.7.3_1610076187313_0.5104197135019426"},"_hasShrinkwrap":false}},"readme":"simple-markdown\n===============\n\nsimple-markdown is a markdown-like parser designed for simplicity\nand extensibility.\n\n[Change log](https://github.com/Khan/simple-markdown/releases)\n\nPhilosophy\n----------\n\nMost markdown-like parsers aim for [speed][marked] or\n[edge case handling][CommonMark].\nsimple-markdown aims for extensibility and simplicity.\n\n[marked]: https://github.com/chjj/marked\n[CommonMark]: https://github.com/jgm/CommonMark\n\nWhat does this mean?\nMany websites using markdown-like languages have custom extensions,\nsuch as `@`mentions or issue number linking. Unfortunately, most\nmarkdown-like parsers don't allow extension without\nforking, and can be difficult to modify even when forked.\nsimple-markdown is designed to allow simple addition of\ncustom extensions without needing to be forked.\n\nAt Khan Academy, we use simple-markdown to format\nover half of our math exercises, because we need\n[markdown extensions][PerseusMarkdown] for math text and\ninteractive widgets.\n\n[PerseusMarkdown]: https://github.com/Khan/perseus/blob/master/src/perseus-markdown.jsx\n\nsimple-markdown is [MIT licensed][LICENSE].\n\n[LICENSE]: https://github.com/Khan/simple-markdown/blob/master/LICENSE\n\nGetting started\n---------------\n\nFirst, let's parse and output some generic markdown using\nsimple-markdown.\n\nIf you want to run these examples in\nnode, you should run `npm install` in the simple-markdown\nfolder or `npm install simple-markdown` in your project's\nfolder. Then you can acquire the `SimpleMarkdown` variable\nwith:\n\n```javascript\n    var SimpleMarkdown = require(\"simple-markdown\");\n```\n\nThen let's get a basic markdown parser and outputter.\n`SimpleMarkdown` provides default parsers/outputters for\ngeneric markdown:\n\n```javascript\n    var mdParse = SimpleMarkdown.defaultBlockParse;\n    var mdOutput = SimpleMarkdown.defaultOutput;\n```\n\n`mdParse` can give us a syntax tree:\n\n```javascript\n    var syntaxTree = mdParse(\"Here is a paragraph and an *em tag*.\");\n```\n\nLet's inspect our syntax tree:\n\n```javascript\n    // pretty-print this with 4-space indentation:\n    console.log(JSON.stringify(syntaxTree, null, 4));\n    => [\n        {\n            \"content\": [\n                {\n                    \"content\": \"Here is a paragraph and an \",\n                    \"type\": \"text\"\n                },\n                {\n                    \"content\": [\n                        {\n                            \"content\": \"em tag\",\n                            \"type\": \"text\"\n                        }\n                    ],\n                    \"type\": \"em\"\n                },\n                {\n                    \"content\": \".\",\n                    \"type\": \"text\"\n                }\n            ],\n            \"type\": \"paragraph\"\n        }\n    ]\n```\n\nThen to turn that into an array of React elements, we can\ncall `mdOutput`:\n\n```javascript\n    mdOutput(syntaxTree)\n    => [ { type: 'div',\n        key: null,\n        ref: null,\n        _owner: null,\n        _context: {},\n        _store: { validated: false, props: [Object] } } ]\n```\n\n\nAdding a simple extension\n-------------------------\n\nLet's add an underline extension! To do this, we'll need to create\na new rule and then make a new parser/outputter. The next section\nwill explain how all of these steps work in greater detail. (To\nfollow along with these examples, you'll also need\n[underscore][underscore].)\n\n[underscore]: http://underscorejs.org/\n\nFirst, we create a new rule. We'll look for double underscores\nsurrounding text.\n\nWe'll put underlines right\nbefore `em`s, so that `__` will be parsed before `_`\nfor emphasis/italics.\n\nA regex to capture this would look something\nlike `/^__([\\s\\S]+?)__(?!_)/`. This matches `__`, followed by\nany content until it finds another `__` not followed by a\nthird `_`.\n\n```javascript\n    var underlineRule = {\n        // Specify the order in which this rule is to be run\n        order: SimpleMarkdown.defaultRules.em.order - 0.5,\n        \n        // First we check whether a string matches\n        match: function(source) {\n            return /^__([\\s\\S]+?)__(?!_)/.exec(source);\n        },\n        \n        // Then parse this string into a syntax node\n        parse: function(capture, parse, state) {\n            return {\n                content: parse(capture[1], state)\n            };\n        },\n        \n        // Finally transform this syntax node into a\n        // React element\n        react: function(node, output) {\n            return React.DOM.u(null, output(node.content));\n        },\n\n        // Or an html element:\n        // (Note: you may only need to make one of `react:` or\n        // `html:`, as long as you never ask for an outputter\n        // for the other type.)\n        html: function(node, output) {\n            return '<u>' + output(node.content) + '</u>';\n        },\n    };\n```\n\nThen, we need to add this rule to the other rules:\n\n```javascript\n    var rules = _.extend({}, SimpleMarkdown.defaultRules, {\n        underline: underlineRule\n    });\n```\n\nFinally, we need to build our parser and outputters:\n\n```javascript\n    var rawBuiltParser = SimpleMarkdown.parserFor(rules);\n    var parse = function(source) {\n        var blockSource = source + \"\\n\\n\";\n        return rawBuiltParser(blockSource, {inline: false});\n    };\n    // You probably only need one of these: choose depending on\n    // whether you want react nodes or an html string:\n    var reactOutput = SimpleMarkdown.reactFor(SimpleMarkdown.ruleOutput(rules, 'react'));\n    var htmlOutput = SimpleMarkdown.htmlFor(SimpleMarkdown.ruleOutput(rules, 'html'));\n```\n\nNow we can use our custom `parse` and `output` functions to parse\nmarkdown with underlines!\n\n```javascript\n    var syntaxTree = parse(\"__hello underlines__\");\n    console.log(JSON.stringify(syntaxTree, null, 4));\n    => [\n        {\n            \"content\": [\n                {\n                    \"content\": [\n                        {\n                            \"content\": \"hello underlines\",\n                            \"type\": \"text\"\n                        }\n                    ],\n                    \"type\": \"underline\"\n                }\n            ],\n            \"type\": \"paragraph\"\n        }\n    ]\n    \n    reactOutput(syntaxTree)\n    => [ { type: 'div',\n        key: null,\n        ref: null,\n        _owner: null,\n        _context: {},\n        _store: { validated: false, props: [Object] } } ]\n\n    htmlOutput(syntaxTree)\n\n    => '<div class=\"paragraph\"><u>hello underlines</u></div>'\n```\n\n\nBasic parsing/output API\n------------------------\n\n#### `SimpleMarkdown.defaultBlockParse(source)`\n\nReturns a syntax tree of the result of parsing `source` with the\ndefault markdown rules. Assumes a block scope.\n\n#### `SimpleMarkdown.defaultInlineParse(source)`\n\nReturns a syntax tree of the result of parsing `source` with the\ndefault markdown rules, where `source` is assumed to be inline text.\nDoes not emit `<p>` elements. Useful for allowing inline markdown\nformatting in one-line fields where paragraphs, lists, etc. are\ndisallowed.\n\n#### `SimpleMarkdown.defaultImplicitParse(source)`\n\nParses `source` as block if it ends with `\\n\\n`, or inline if not.\n\n#### `SimpleMarkdown.defaultOutput(syntaxTree)`\n\nReturns React-renderable output for `syntaxTree`.\n\n*Note: raw html output will be coming soon*\n\n\nExtension Overview\n------------------\n\nElements in simple-markdown are generally created from rules.\nFor parsing, rules must specify `match` and `parse` methods.\nFor output, rules must specify a `react` or `html` method\n(or both), depending on which outputter you create afterwards.\n\nHere is an example rule, a slightly modified version of what\nsimple-markdown uses for parsing **strong** (**bold**) text:\n\n```javascript\n    strong: {\n        match: function(source, state, lookbehind) {\n            return /^\\*\\*([\\s\\S]+?)\\*\\*(?!\\*)/.exec(source);\n        },\n        parse: function(capture, recurseParse, state) {\n            return {\n                content: recurseParse(capture[1], state)\n            };\n        },\n        react: function(node, recurseOutput) {\n            return React.DOM.strong(null, recurseOutput(node.content));\n        },\n        html: function(node, recurseOutput) {\n            return '<strong>' + recurseOutput(node.content) + '</strong>';\n        },\n    },\n```\n\nLet's look at those three methods in more detail.\n\n#### `match(source, state, lookbehind)`\n\nsimple-markdown calls your `match` function to determine whether the\nupcoming markdown source matches this rule or not.\n\n`source` is the upcoming source, beginning at the current position of\nparsing (source[0] is the next character).\n\n`state` is a mutable state object to allow for more complicated matching\nand parsing. The most common field on `state` is `inline`, which all of\nthe default rules set to true when we are in an inline scope, and false\nor undefined when we are in a block scope.\n\n**DEPRECATED - use `state.prevCapture` instead.** `lookbehind` is the string previously captured at this parsing level, to\nallow for lookbehind. For example, lists check that lookbehind ends with\n`/^$|\\n *$/` to ensure that lists only match at the beginning of a new\nline.\n\nIf this rule matches, `match` should return an object, array, or\narray-like object, which we'll call `capture`, where `capture[0]`\nis the full matched source, and any other fields can be used in the\nrule's `parse` function. The return value from `Regexp.prototype.exec`\nfits this requirement, and the common use case is to return the result\nof `someRegex.exec(source)`.\n\nIf this rule does not match, `match` should return null.\n\nNOTE: If you are using regexes in your match function, your regex\nshould always begin with `^`. Regexes without leading `^`s can\ncause unexpected output or infinite loops.\n\n#### `parse(capture, recurseParse, state)`\n\n`parse` takes the output of `match` and transforms it into a syntax\ntree node object, which we'll call `node` here.\n\n`capture` is the non-null result returned from match.\n\n`recurseParse` is a function that can be called on sub-content and\nstate to recursively parse the sub-content. This returns an array.\n\n`state` is the mutable state threading object, which can be examined\nor modified, and should be passed as the third argument to any\n`recurseParse` calls.\n\nFor example, to parse inline sub-content, you can add `inline: true`\nto state, or `inline: false` to force block parsing (to leave the\nparsing scope alone, you can just pass `state` with no modifications).\nFor example:\n\n```javascript\n    var innerText = capture[1];\n    recurseParse(innerText, _.defaults({\n        inline: true\n    }, state));\n```\n    \n`parse` should return a `node` object, which can have custom fields\nthat will be passed to `output`, below. The one reserved field is\n`type`, which designates the type of the node, which will be used\nfor output. If no type is specified, simple-markdown will use the\ncurrent rule's type (the common case). If you have multiple ways\nto parse a single element, it can be useful to have multiple rules\nthat all return nodes of the same type.\n\n#### `react(node, recurseOutput, state)`\n\n`react` takes a syntax tree `node` and transforms it into\nReact-renderable output.\n\n`node` is the return value from `parse`, which has a type\nfield of the same type as the current rule, as well as any\ncustom fields created by `parse`.\n\n`recurseOutput` is a function to recursively output sub-tree\nnodes created by using `recurseParse` in `parse`.\n\n`state` is the mutable state threading object, which can be\nexamined or modified, and should be passed as the second\nargument to any recurseOutput calls.\n\nThe simple-markdown API contains several helper methods for\ncreating rules, as well as methods for creating parsers and\noutputters from rules.\n\nExtension API\n-------------\n\nsimple-markdown includes access to the default list of rules,\nas well as several functions to allow you to create parsers and\noutputters from modifications of those default rules, or even\nfrom a totally custom rule list.\n\nThese functions are separated so that you can customize\nintermediate steps in the parsing/output process, if necessary.\n\n#### `SimpleMarkdown.defaultRules`\n\nThe default rules, specified as an object, where the keys are\nthe rule types, and the values are objects containing `order`,\n`match`, `parse`, `react`, and `html` fields (these rules can\nbe used for both parsing and outputting).\n\n#### `SimpleMarkdown.parserFor(rules)`\n\nTakes a `rules` object and returns a parser for the rule types\nin the rules object, in order of increasing `order` fields,\nwhich must be present and a finite number for each rule.\nIn the case of order field ties, rules are ordered\nlexicographically by rule name. Each of the rules in the `rules`\nobject must contain a `match` and a `parse` function.\n\n#### `SimpleMarkdown.ruleOutput(rules, key)`\n\nTakes a `rules` object, containing an `output` function for\neach rule, and a `key` into individual elements in that rules\nrules argument (either `'react'` or `'html'`, unless you are\ndefining a custom output type), and returns a function that can\noutput a single syntax tree node of any type that is in the\n`rules` object, given a node and a recursive output function.\nThis is not the final output function because it doesn't handle\narrays of nodes or recursion (see `reactFor` and `htmlFor`).\n\n#### `SimpleMarkdown.reactFor(singleNodeOutputFunction)`\n\nTakes a function that can output react-renderable output for\nany single syntax tree node and returns a function that maps\nover syntax tree arrays correctly.\n\nThe most common use case is to pass the output of\n`ruleOutput` as the parameter to `reactFor`:\n\n```javascript\n    var output = SimpleMarkdown.reactFor(SimpleMarkdown.ruleOutput(rules, 'react'));\n```\n\n#### `SimpleMarkdown.htmlFor(singleNodeOutputFunction)`\n\nTakes a function that can output an html string for\nany single syntax tree node and returns a function that maps\nover syntax tree arrays correctly.\n\nThe most common use case is to pass the output of\n`ruleOutput` as the parameter to `htmlFor`:\n\n```javascript\n    var output = SimpleMarkdown.htmlFor(SimpleMarkdown.ruleOutput(rules, 'html'));\n```\n\n#### Putting it all together\n\nGiven a set of rules, one can create a single function\nthat takes an input content string and outputs a\nReact-renderable as follows. Note that since many rules\nexpect blocks to end in `\"\\n\\n\"`, we append that to source\ninput manually, in addition to specifying `inline: false`\n(`inline: false` is technically optional for all of the\ndefault rules, which assume `inline` is false if it is\nundefined).\n\n```javascript\nvar rules = {\n    ...SimpleMarkdown.defaultRules,\n    paragraph: {\n        ...SimpleMarkdown.defaultRules.paragraph,\n        react: (node, output, state) => {\n            return <p key={state.key}>{output(node.content, state)}</p>;\n        }\n    }\n};\n\nvar parser = SimpleMarkdown.parserFor(rules);\nvar reactOutput = SimpleMarkdown.reactFor(SimpleMarkdown.ruleOutput(rules, 'react'));\nvar htmlOutput = SimpleMarkdown.reactFor(SimpleMarkdown.ruleOutput(rules, 'html'));\n\nvar blockParseAndOutput = function(source) {\n    // Many rules require content to end in \\n\\n to be interpreted\n    // as a block.\n    var blockSource = source + \"\\n\\n\";\n    var parseTree = parser(blockSource, {inline: false});\n    var outputResult = htmlOutput(parseTree);\n    // Or for react output, use:\n    // var outputResult = reactOutput(parseTree);\n    return outputResult;\n};\n```\n\nExtension rules helper functions\n--------------------------------\n\n*Coming soon*\n\nLICENSE\n-------\nMIT. See the LICENSE file for text.\n","maintainers":[{"name":"xymostech","email":"xymostech@gmail.com"},{"name":"ariabuckles","email":"aria@toole1.com"},{"name":"khanacademy","email":"opensource+npm@khanacademy.org"}],"time":{"modified":"2022-06-26T19:43:50.844Z","created":"2015-02-24T03:49:13.176Z","0.0.2":"2015-02-24T03:49:13.176Z","0.0.3":"2015-04-26T17:50:17.120Z","0.0.4":"2015-10-16T22:15:49.981Z","0.0.5":"2015-11-06T17:02:59.782Z","0.0.6":"2015-11-23T23:37:13.245Z","0.0.7":"2015-11-23T23:55:34.946Z","0.0.8":"2016-01-30T00:17:05.765Z","0.0.9":"2016-02-01T20:12:30.467Z","0.1.0":"2016-05-26T18:01:04.557Z","0.1.1":"2016-06-10T01:35:24.262Z","0.1.2":"2016-10-17T20:59:25.318Z","0.2.0":"2016-10-17T21:01:16.739Z","0.2.1":"2016-10-19T02:57:57.091Z","0.2.2":"2017-09-03T03:04:16.577Z","0.3.0":"2017-09-03T03:05:29.003Z","0.3.1":"2017-09-13T19:07:18.287Z","0.3.2":"2018-01-05T22:53:16.119Z","0.3.3":"2018-03-11T01:13:40.870Z","1.0.0-alpha.0":"2018-03-16T02:55:49.707Z","0.4.0":"2018-04-27T19:34:30.608Z","0.4.1":"2018-05-16T21:41:06.613Z","0.4.2":"2018-08-28T16:54:25.774Z","0.4.3":"2019-03-13T20:48:41.671Z","0.4.4":"2019-03-14T20:45:25.003Z","0.5.0":"2019-08-05T01:27:37.095Z","0.5.1":"2019-08-05T16:22:37.005Z","0.5.2":"2019-08-31T22:22:42.667Z","0.5.3":"2019-09-19T01:42:45.880Z","0.6.0":"2019-09-19T01:43:15.749Z","0.6.1":"2019-10-24T23:18:25.121Z","0.7.0":"2019-10-24T23:28:57.011Z","0.7.1":"2019-11-04T00:20:15.944Z","0.7.2":"2019-12-30T22:00:13.513Z","0.7.3":"2021-01-08T03:23:07.505Z"},"homepage":"https://github.com/Khan/simple-markdown","keywords":["markdown","simple","react","html","ast","markup","text processing","extension","flow","typescript"],"repository":{"type":"git","url":"git+https://github.com/Khan/simple-markdown.git"},"author":{"name":"Aria Buckles"},"bugs":{"url":"https://github.com/Khan/simple-markdown/issues"},"license":"MIT","readmeFilename":"README.md","users":{"ariabuckles":true}}