Skip to content

Commit 9154755

Browse files
authored
Improve tutorial (#181)
2 parents bb1be46 + a4edfa6 commit 9154755

File tree

1 file changed

+17
-9
lines changed

1 file changed

+17
-9
lines changed

content/terms/tutorial/track.md

Lines changed: 17 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -36,20 +36,29 @@ By the end, you'll have tracked a service's privacy policy. You will also have a
3636

3737
For this tutorial, we will use the Privacy Policy of Open Terms Archive as an example.
3838

39-
Create a file `declarations/Open Terms Archive.json`. The name of the file is the name of the service that will be tracked. The first thing to declare is the tracked service name:
39+
1. Create a file `declarations/Open Terms Archive.json`. The name of the file is the name of the service that will be tracked. The first thing to declare is the tracked service name:
40+
4041
```json
4142
{
4243
"name": "Open Terms Archive"
4344
}
4445
```
4546

46-
Now, you can add terms you want to track to the declaration. For this example, we will use the Privacy Policy.
47+
2. Find the URL of Open Terms Archive Privacy Policy by browsing [the website](https://opentermsarchive.org), copy the URL and fill the `fetch` field with.
4748

48-
You can go on the Open Terms Archive [website](https://opentermsarchive.org/) and copy the URL of its [Privacy Policy](https://opentermsarchive.org/en/privacy-policy/) to fill the `fetch` field.
49+
```json
50+
{
51+
"name": "Open Terms Archive",
52+
"terms": {
53+
"Privacy Policy": {
54+
"fetch": "https://opentermsarchive.org/en/privacy-policy"
55+
}
56+
}
57+
}
58+
```
4959

50-
And you can inspect the HTML of the page to get the selector of the content you want to extract to fill the `select` field.
60+
3. [Use a DOM inspector](https://developer.mozilla.org/en-US/docs/Learn_web_development/Core/Structuring_content/Debugging_HTML#using_a_dom_inspector) on the Open Terms Archive [Privacy Policy page](https://opentermsarchive.org/en/privacy-policy) to get the [CSS selector](https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_selectors) of the content you want to extract. Add it to the `select` field. The final declaration should look like this:
5161

52-
The resulting declaration should look something like this:
5362
```json
5463
{
5564
"name": "Open Terms Archive",
@@ -74,8 +83,7 @@ The resulting declaration should look something like this:
7483
npx ota track
7584
```
7685

77-
3. Verify the results:
78-
- Check the extracted version, which should contain the Privacy Policy of Open Terms Archive in Markdown format without any other content (no header, footer…): `./data/versions/Open Terms Archive/Privacy Policy.md`.
79-
- Check the snapshot, which is the original HTML document of the Open Terms Archive Privacy Policy: `./data/snapshots/Open Terms Archive/Privacy Policy.html`.
86+
3. Verify the results by checking the extracted version in `./data/versions/Open Terms Archive/Privacy Policy.md` file, which should contain only the meaningful content of the Privacy Policy in Markdown format.
87+
88+
Congratulations! You have tracked your first terms locally.
8089

81-
Congratulations! You have tracked your first terms.

0 commit comments

Comments
 (0)