Skip to content

Commit 217892b

Browse files
committed
Improve docs
1 parent 55e01c8 commit 217892b

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -325,7 +325,7 @@ All Indexing API functions are Promise-based.
325325

326326
### Document structure
327327
Documents can contain a set of pre-defined fields, as well as any number of custom fields
328-
defined under the custom_fields key.
328+
defined under the **custom_fields** key.
329329

330330
Using pre-defined fields is optional, but default [Search UI](https://github.com/AddSearch/search-ui) components
331331
display them by default, so they give you visible results faster.
@@ -359,8 +359,8 @@ Dates should be defined as UNIX timestamps with integer values.
359359

360360
### Document ID
361361

362-
If the id field is not defined in the document, it is generated automatically either randomly
363-
or from the URL field, when the document is added to the index.
362+
If the **id** is not defined in the document at indexing time, it is generated automatically either randomly
363+
or from the **url** field.
364364

365365
```js
366366
// ID defined by the user
@@ -370,9 +370,9 @@ const docWithDefinedId = {
370370
}
371371
```
372372
```js
373-
// ID created from the URL field (md5 sum)
373+
// ID created from the URL field (md5 of the url)
374374
const docWithURL= {
375-
url: 'https://..', // id will be md5('https://..')
375+
url: 'https://..',
376376
custom_fields: {}
377377
}
378378
```

0 commit comments

Comments
 (0)