example_url | http://cooper.com/journal/2012/08/the-best-interface-is-no-interface.html |
---|---|
domain_re | ^(www\.)?cooper\.com$ |
rules | {"comment":{"from":"css #comments .comment-count","to":"css #comments-open","items":"css* #comments .comment"}} |
Database: Fold Comments
http://userscripts.org/scripts/show/19344 is just begging to become a WeData-backed extension. What it does? It folds up large comment sections in web pages you visit (and unfolds, if you like), so you get a feel for how long the web page or article itself is by peeking at the window scrollbar.
The rules property is a JSON DOM spec that describes all foldable sections in the page, giving each a name, a "from" and "to" element, and an optional "items" array enumerating the respective individual items themselves, with css and/or xpath selectors, in the format https://gist.github.com/3957352 defines.
Alternatively, if the rules property is a URL, it references another wedata item (which has a non-url rules property), inheriting the rules dom spec it carries.
Last Update: 2012-11-03T01:31:39+09:00 History
Item List
-
Cooper Journal comments 2012-11-02T13:50:35+09:00
last update: 2012-11-02T14:02:55+09:00
-
Paul Graham essays 2012-11-02T13:24:41+09:00
example_url http://paulgraham.com/love.html domain paulgraham.com rules {"footnote":["xpath //b[.='Notes']",{"from":"xpath .","to":"xpath //a[starts-with(@name,'f')][last()]/following-sibling::br[1]","items":"xpath* ../a[starts-with(@name,'f')]"}]} last update: 2012-11-02T13:58:46+09:00