Open source is a gift given by whoever wants, and it's amazing to be in a place in life when you can give if you want to, but it's all 'bonus'.
1,690 karma · joined April 1, 2013
Open source is a gift given by whoever wants, and it's amazing to be in a place in life when you can give if you want to, but it's all 'bonus'.
- A single-page HTML app that saved entries in localStorage in 1 browser (like 1kb of vanilla CSS and JS, barely anything)
- A static HTML website, generated from a folder of Markdown-like raw text, with a CLI build script. Hosted on a public web server.
- A simple linux CLI command that let me check, set, and mark items as complete, build with Node and saved to a JSON on disk somewhere.
And there must have been one or two more. Nothing serious, nothing that stuck long-term, but I probably spent 1-10 hours making these, and then using them daily for a year or a year and a half.
I'm very conscious about time spent automating or building what you want, versus how much real-life time savings or experience boost does it give you. I'll likely make more of these in the future when the itch reappears and hopefully get another year's enjoyment out of whatever little thing I build.
Right now the problem I have is that text that's been marked up as HTML suddenly then becomes harder to wrangle around than it was to put it into HTML in the first place.
I want an editor where I can "select all <p>" or "search and replace all <h2> tag names with <h1> tag names while leaving attributes intact" and other ways of reasoning about HTML as HTML in my editor.
Isn't it weird how we're so acutely aware of the effect of the species that invade our space, but so ignorant so often of our effect on the same spaces when we invade them?
I think I learned something valuable today chewing on this article.
So it's not that they're a bad band, or bad at writing songs, we just got tired of that one formula and they kept doing it as long as it made them money.
It seems to work okay the other direction though, if code is well-named and well-commented, ChatGPT can explain what it does in natural language tailored to people of varying backgrounds and levels of experience. But it's not so good at taking natural language and making it into code that has to be much stricter.
The approach is to take the JavaScript object, convert it to XML DOM, run the query (either using standard XPath, or standard CSS selectors) and then either convert the DOM back into objects, or another way I've seen it done is to keep a register of the original objects and retrieve the original objects.
In this way, JSON, and any JavaScript object with non-circularity can be sifted and searched and filtered in reliable ways using already-standardized methods just by using those technologies together in a fun new way.
There is not necessarily a need for inventing a new custom syntax/DSL for querying unless you don't want to make use of CSS and XPath, or have very specific needs.
I see 2 things that are good news here, the first is that you reached out to others for help, speaking purely statistically this is a good indicator that you are a survivor! The second good news is that much of the AI hype you're hearing is embellished for profit. Things feel really bleak because of where your head is at right now, and that can change!
Please go get help from the people waiting to give it to you, you can make it through even this!
So if a function in CSS is func(), then a custom author-defined function will always be --func() and it should be parsed and safely ignored by browsers or things that don't understand it, but still present in your CSS for tools to read and operate on so you can define custom features and use them within standard CSS no matter how or where you are providing the support (you could process some things in advance like a preprocessor, or it might be a feature that only makes sense to support client-side in a browser or at the time the CSS is being evaluated).
Why can't we extend standards-based languages using the built-in custom extensibility they already have?