Live data from Hacker News

Browser extensions are underrated: the promise of hackable software (2019)

geoffreylitt.com

291–300 of 320 posts

Re: Browser extensions are underrated: the promise of hackable software (2019)

#291
post #200

> Browser extensions remind us what it’s like to have deep control over how we use our computers. Uh. Linux users would like a word here. But more generally, there's a significant component of this that seems isomorphous to the question I was trying to discuss in a post I wrote several years ago called "Is Open Source a diversion from what users really want?" There seems to be much more excitement about ways to "hack…

> Uh. Linux users would like a word here. The shift of Linux to systemd was a very similar experience to the decline of browser extensions. Yes, you can change how your computer works. But unless you're willing to put a lot of effort into maintaining those changes, the APIs you use will be cut out from under you and it'll be harder and harder to make your computer do what you wanted rather than what someone else thou…

Just my own experience, but I've actually had more fun and more success using systemd to do funny stuff with my PC than with sysvinit. Can't speak to the other init systems though.

Re: Browser extensions are underrated: the promise of hackable software (2019)

#292

I love working with hackable software. I kind of attack it at the source level vs writing for the browser however. For example, say there’s some tool on a git repo. I will shamelessly clone it and build off of it to my own liking. Maybe I add another 1% to the code base, or maybe that repo becomes 1% of a codebase I write on my own. These are tools I could never share however, because of the rampant plagiarism I am d…

Plagiarism? The vast majority of codebases I've seen on GitHub specifically allow you to do what you are doing. No need to make it sound like a bad thing.

Re: Browser extensions are underrated: the promise of hackable software (2019)

#293

Earlier quoted context omitted.

"I don't care to live in strategically lost situatios like this, so I think the conversation should be about Firefox extensions." Why would the conversation not be about editing the Firefox source code to add or remove "features" to meet one's personal needs. What is the point of "open source" if, to use the term from the submission title, the software is effectively un-"hackable". There is no small amount of "attack…

Unlike you I don't have a dislike of graphics. I do however see value in small simple software. The Web is a runtime so very complex that it takes huge organizations to create. Theoretically, you could sacrifice full compatibility by implementing only the APIs used for Google, Facebook, YouTube, Reddit, Amazon etc. and have something much simpler. But that would still be a hard task because you are making a big compa…

"I do however see value in small simple software."

Years ago on HN, I had commenters attack statements I made about the value of small, simple software. They literally challenged the terms "small" and "simple". After that I started prefacing these words with "relatively".

"When evaluating software utility..."

Another time, an HN commenter attacked a statement I made about how I evaluate software for myself. He suggested something to the effect that end users were incapable of evaluating software.

Re: Browser extensions are underrated: the promise of hackable software (2019)

#294
post #200

Earlier quoted context omitted.

> Uh. Linux users would like a word here. The shift of Linux to systemd was a very similar experience to the decline of browser extensions. Yes, you can change how your computer works. But unless you're willing to put a lot of effort into maintaining those changes, the APIs you use will be cut out from under you and it'll be harder and harder to make your computer do what you wanted rather than what someone else thou…

Just my own experience, but I've actually had more fun and more success using systemd to do funny stuff with my PC than with sysvinit. Can't speak to the other init systems though.

I've just reached the learned helplessness point where it feels like it's not worth learning anything because it's going to change again by the time I use it. Right now I've got a service that starts every boot that I stop manually each time because I can't figure out how to disable it; even if older init was "worse", it was "just" a shell script so I could do stuff like commenting out lines without having to go into the details.

Re: Browser extensions are underrated: the promise of hackable software (2019)

#295
post #69

I prefer bookmarklets because they - Are easy to edit - Are inactive until clicked - Work in all browsers - Work on mobile - Integrate nicely into the UI. I can move them around, put them into any bookmark folder, assign shortcuts. I wrote this bookmarlet editor which makes it easy to convert between clean code and a bookmarklet: https://www.gibney.org/bookmarklet_editor

Well that's a handy site you have there. Last time I fiddled with bookmarklets they didn't work on Firefox for Android, but now they do. This is going to be handy combining it with my Node-red instance. Got any good bookmarklets you want to share?

edit any text on webpage

    javascript: (function() {   document.body.contentEditable = true;   document.body.spellcheck = false;  })();
Open on wayback machine

    javascript:location.href='https://web.archive.org/web/*/'+document.location.href.replace(/\/$/, '');
Others that are longer https://github.com/madacol/web-automation/tree/master/bookma...

Re: Browser extensions are underrated: the promise of hackable software (2019)

#296

Earlier quoted context omitted.

Well that's a handy site you have there. Last time I fiddled with bookmarklets they didn't work on Firefox for Android, but now they do. This is going to be handy combining it with my Node-red instance. Got any good bookmarklets you want to share?

edit any text on webpage javascript: (function() { document.body.contentEditable = true; document.body.spellcheck = false; })(); Open on wayback machine javascript:location.href='https://web.archive.org/web/*/'+document.location.href.replace(/\/$/, ''); Others that are longer https://github.com/madacol/web-automation/tree/master/bookma...

An interesting one I made recently is related to a game published a couple of days ago here in HN called "infinite craft" https://neal.fun/infinite-craft/

The game does not have any save mechanism, so I made a bookmarklet that loads and autosaves to localStorage

```

javascript:(function(){ const exportState = () => JSON.stringify({ discoveries: window.$nuxt.$root.$children[2].$children[0].$children[0]._data.discoveries, elements: window.$nuxt.$root.$children[2].$children[0].$children[0]._data.elements });

    const importState = (state) => {
        const { discoveries, elements } = JSON.parse(state);
        const gameInstance = window.$nuxt.$root.$children[2].$children[0].$children[0]._data;
        gameInstance.discoveries = discoveries;
        gameInstance.elements = elements;
    };

    /* Set up a MutationObserver to listen for changes in the DOM and automatically export the current state. */
    const observer = new MutationObserver((mutations) => {
        const state = exportState();
        localStorage.setItem('gameState', state);
    });

    /* Start observing DOM changes to auto-save the game state. */
    const startObserving = () => {
        const targetNode = document.querySelector('.sidebar');
        observer.observe(targetNode, { childList: true, subtree: true });
    };

    /* Check for a saved state in localStorage and import it if available. */
    const savedState = localStorage.getItem('gameState');
    if (savedState) importState(savedState);
    else localStorage.setItem('gameState', exportState() );

    startObserving();
})();

```

Re: Browser extensions are underrated: the promise of hackable software (2019)

#297

Earlier quoted context omitted.

I don't compile them. I just write the JavaScript and wrap it in an anonymous function then save the code as a bookmark.

Ah, I thought it didn't work to simply paste the javascript directly into the bookmark. Don't you have to minimally URI encode it? `javascript:URI_ENCODED_CODE`

No, Firefox automatically encodes it, but it does have other gotchas because line-breaks are removed

   - You have to put `;` on each statement
   - You cannot use inline comments, // you cannot do this

Re: Browser extensions are underrated: the promise of hackable software (2019)

#298

Earlier quoted context omitted.

Unlike you I don't have a dislike of graphics. I do however see value in small simple software. The Web is a runtime so very complex that it takes huge organizations to create. Theoretically, you could sacrifice full compatibility by implementing only the APIs used for Google, Facebook, YouTube, Reddit, Amazon etc. and have something much simpler. But that would still be a hard task because you are making a big compa…

"I do however see value in small simple software." Years ago on HN, I had commenters attack statements I made about the value of small, simple software. They literally challenged the terms "small" and "simple". After that I started prefacing these words with "relatively". "When evaluating software utility..." Another time, an HN commenter attacked a statement I made about how I evaluate software for myself. He sugges…

I think the presumption of what users want is a kind of classism. Users are humans and as humans we have a hierarchy of needs that can lead to certain tradeoffs. Doesn't mean only the techies appreciate things like privacy and having agency over software. Just because corporations don't give us a choice doesn't mean "the market has decided". So you aren't an outlier you are just aware and maybe more interested in the problem than someone who isn't a programmer.

Re: Browser extensions are underrated: the promise of hackable software (2019)

#299

Earlier quoted context omitted.

How did you jump from > At this point I don't really know if you understand what 'neurodivergent' means. People who suffer for neurodivergency does not have different mental mappings than those who are neurotypical. Also, the way they construct their own world does not differ from neurotypical to > Do you feel that something needs to be addressed about the way LoganDark disclaimed that they were biased on account of…

maybe they think the disclaimer was unnecessary or misguided if there's no actual difference between neurotypical and neurodivergent there?

I think your disclaimer is fine, I just wondered where Malcolmlisk wanted to go with his comment.

Re: Browser extensions are underrated: the promise of hackable software (2019)

#300

Earlier quoted context omitted.

This comment is puzzling to me on several levels, but I'll just go to the centre of the topic. Do you feel that something needs to be addressed about the way LoganDark disclaimed that they were biased on account of their neurodivergency?

How did you jump from > At this point I don't really know if you understand what 'neurodivergent' means. People who suffer for neurodivergency does not have different mental mappings than those who are neurotypical. Also, the way they construct their own world does not differ from neurotypical to > Do you feel that something needs to be addressed about the way LoganDark disclaimed that they were biased on account of…

Well, why is he talking about what neurodivergency means? Why does it matter in this comment thread? I don't see what he wants to say, so I ask.
Post reply on HN