Add support to join multiple blocks in asText() with any string, not only one whitespace as proposed in PR prismicio/prismic-richtext#8 (it makes sense to release that prismic-richtext PR first, but if it isn't it shouldn't break anything, the second arg will just be ignored).
HTML-escape text content to fix #22. An external dependency escape-html was added. It is very small. I locked the version to 1.0.3 to minimise the risk of breaking anything in the future. I also checked that it actually is really fast. In my opinion the dependency is justified.
Implement the preformatted element (<pre>) to fix #24.
Added a few very basic tests (better than nothing).
Other updates:
Included the minor change from PR #23 (Update Babel dev dependencies), which makes #23 redundant.
Updated .travis.yml…
to run the newly added tests
added Node version 8
removed macOS as I believe it doesn't add any value in this case and only doubles build times (comments?)
removed global installation of NPM package tape as it looks like it's redundant.
replaced npm run with yarn run because everything else is run with yarn too.
Updated package.json…
added the test script
changed prismic-richtext dependency from version 0.2.1. to latest 0.4.1
updated Babel dependencies (as in PR #23)
I know, I really should have broken everything down into more PRs, but actually it's not that much.
Main features:
asText()
with any string, not only one whitespace as proposed in PR prismicio/prismic-richtext#8 (it makes sense to release that prismic-richtext PR first, but if it isn't it shouldn't break anything, the second arg will just be ignored).preformatted
element (<pre>
) to fix #24.Other updates:
.travis.yml
…npm run
withyarn run
because everything else is run with yarn too.package.json
…prismic-richtext
dependency from version 0.2.1. to latest 0.4.1I know, I really should have broken everything down into more PRs, but actually it's not that much.