9front - general discussion about 9front
 help / color / mirror / Atom feed
From: hiro <23hiro@gmail.com>
To: 9front@9front.org
Subject: Re: [9front] htmlfs
Date: Thu, 2 Sep 2021 14:32:26 +0200	[thread overview]
Message-ID: <CAFSF3XOM19nkxvtAq4e5O0UwcXqZK+hyAMYmAwYtOuFQR0E2PQ@mail.gmail.com> (raw)
In-Reply-To: <CAFSF3XNo-Pj=iZQhNWaS8Jvw+53UY0J4UKuVRHrMgr9kh=Uc6w@mail.gmail.com>

after writing my last email i googled xpath, and realize that i only
ever got to see a subset of it's insane complexity (the simple path
notation that includes a way to specify this n-th-element of a type,
which i have seen used a lot in practice by adblockers and anything
that needs to scrape content from websites that don't supply
meaningful element names.

contrary, i have indeed seen that some websites randomize their
element names to prevent this kind of javascript-free processing. so
yes, our low effort will not help with websites that really don't want
to be scraped...

On 9/2/21, hiro <23hiro@gmail.com> wrote:
> On 8/31/21, Pavel Renev <an2qzavok@gmail.com> wrote:
>> I have a half-backed DOMfs:
>> http://git.nsmpr.xyz/domfs/files.html
>> but it just represents documents as a flat list of numbered nodes (the
>> way
>> rio serves its windows) and their hierarchy is provided through a
>> separate
>> file.
>>
>> The challenge with xml/html is that unlike traditional file trees their
>> elements do not have unique names and instead addressed by their order.
>> Additionaly, element's attributes often play bigger role than text data
>> they
>> contain.
>> Style also can override tree hierarchy when it comes to rendering, and
>> when
>> it comes to javascript, programs look up needed elements via global
>> search
>> by id and usually only care about element's immediate parent/children.
>>
>> TL;DR: the tree is a lie.
>> Maybe serving html via some kind of database query interface would be
>> better.
>>
>
> why not do like xpath? numbers can signify order.
> we don't support javascript anyway, so the tree wouldn't really change
> under our feet...
>

      reply	other threads:[~2021-09-02 14:13 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-29 21:05 Philip Silva
2021-08-30  4:12 ` Amavect
2021-08-31  5:33   ` unobe
2021-08-31  9:46     ` jstsmthrgk
2021-08-31 10:36       ` hiro
2021-08-31 12:29         ` Steve Simon
2021-09-01  6:53           ` hiro
2021-09-01  8:30             ` sirjofri
2021-09-01  9:02               ` kvik
2021-08-31 20:09     ` hiro
2021-08-31 22:40       ` Stuart Morrow
2021-08-31 11:49   ` hiro
2021-08-31 15:42     ` Philip Silva
2021-08-31  5:23 ` unobe
2021-08-31 13:20 ` Pavel Renev
2021-08-31 15:40   ` Philip Silva
2021-09-02 11:44   ` hiro
2021-09-02 12:32     ` hiro [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAFSF3XOM19nkxvtAq4e5O0UwcXqZK+hyAMYmAwYtOuFQR0E2PQ@mail.gmail.com \
    --to=23hiro@gmail.com \
    --cc=9front@9front.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).