Skip to content

Commit

Permalink
docs: fix quickstart (#419)
Browse files Browse the repository at this point in the history
sashkab authored Sep 15, 2023
1 parent 5ce31d9 commit 0fbc1cb
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions docs/quickstart.rst
Original file line number Diff line number Diff line change
@@ -19,13 +19,13 @@ The only required argument is the input document (here a downloaded HTML file),
>>> downloaded = fetch_url('https://github.blog/2019-03-29-leader-spotlight-erin-spiceland/')
# output main content and comments as plain text
>>> result = trafilatura.extract(downloaded)
>>> result = extract(downloaded)
# change the output format to XML (allowing for preservation of document structure)
>>> result = trafilatura.extract(downloaded, output_format="xml")
>>> result = extract(downloaded, output_format="xml")
# discard potential comment and change the output to JSON
>>> trafilatura.extract(downloaded, output_format="json", include_comments=False)
>>> extract(downloaded, output_format="json", include_comments=False)
The use of fallback algorithms can also be bypassed in fast mode:

@@ -75,4 +75,3 @@ Extraction options are also available on the command-line, they can be combined:
For more information please refer to `usage documentation <usage.html>`_ and `tutorials <tutorials.html>`_.

0 comments on commit 0fbc1cb

Please sign in to comment.