1
0
mirror of https://github.com/MontFerret/ferret.git synced 2025-01-24 03:49:29 +02:00
ferret/examples/static-page.fql

14 lines
377 B
Plaintext
Raw Normal View History

2018-10-07 02:24:29 -04:00
LET doc = DOCUMENT("https://github.com/topics")
2018-09-18 16:42:38 -04:00
2018-10-07 02:24:29 -04:00
FOR el IN ELEMENTS(doc, ".py-4.border-bottom")
LIMIT 10
LET url = ELEMENT(el, "a")
LET name = ELEMENT(el, ".f3")
LET description = ELEMENT(el, ".f5")
2018-10-07 02:24:29 -04:00
RETURN {
name: TRIM(name.innerText),
description: TRIM(description.innerText),
2018-10-07 02:24:29 -04:00
url: "https://github.com" + url.attributes.href
}