docs: add install build and test guide (#215)

* docs: add install build and test guide

* docs: remove install build and test guides

* docs: add installation guide
pull/216/head^2
Ralph Jbeily 5 years ago committed by GitHub
parent 2e1e4d90c9
commit ca44ce3dd1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -8,6 +8,14 @@ The Mercury Parser module powers the [Mercury Parser API](https://mercury.postli
## How? Like this.
### Installation
```bash
yarn add mercury-parser
```
### Usage
```javascript
import Mercury from 'mercury-parser';
@ -46,6 +54,9 @@ If you'd like to write a custom parser for a site, [here's how](src/extractors/c
[![All Contributors](https://img.shields.io/badge/all_contributors-4-orange.svg?style=flat-square)](#contributors)
<!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section -->
| [<img src="https://avatars.githubusercontent.com/u/64131?v=3" width="100px;"/><br /><sub>Adam Pash</sub>](http://adampash.com)<br />📝 [💻](https://github.com/postlight/readability-parser/commits?author=adampash) [📖](https://github.com/postlight/readability-parser/commits?author=adampash) 💡 | [<img src="https://avatars.githubusercontent.com/u/19412836?v=3" width="100px;"/><br /><sub>Toy Vano</sub>](https://github.com/spiffytoy)<br />[💻](https://github.com/postlight/readability-parser/commits?author=spiffytoy) | [<img src="https://avatars.githubusercontent.com/u/183608?v=3" width="100px;"/><br /><sub>Drew Bell</sub>](droob.org)<br />[💻](https://github.com/postlight/readability-parser/commits?author=droob) | [<img src="https://avatars.githubusercontent.com/u/305901?v=3" width="100px;"/><br /><sub>Jeremy Mack</sub>](https://twitter.com/mutewinter)<br />[💻](https://github.com/postlight/readability-parser/commits?author=mutewinter) |
| :---: | :---: | :---: | :---: |
| :---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------: | :---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------: | :---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------: | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------: |
<!-- ALL-CONTRIBUTORS-LIST:END -->

@ -185,7 +185,7 @@ For our New Yorker example, we're going to use [this story](http://www.newyorker
When the generator script completes, you'll be prompted to run:
```bash
yarn watch:test -- www.newyorker.com
yarn watch:test www.newyorker.com
```
This will run the tests for the parser you just generated, which should fail (which makes sense — you haven't written it yet!). Your goal now is to follow the instructions in the generated `www.newyorker.com/index.test.js` and `www.newyorker.com/index.js` files until they pass!
@ -253,7 +253,7 @@ AssertionError: 'Hacking, Cryptography, and the Countdown to Quantum Computing'
'Schrödingers Hack';
```
When Mercury generated our test, it took a guess at the page's title, and in this case, it got it wrong. So update the test with thte title we expect, save it, and your test should pass!
When Mercury generated our test, it took a guess at the page's title, and in this case, it got it wrong. So update the test with the title we expect, save it, and your test should pass!
### Step 3: Speed it up

Loading…
Cancel
Save