This is just a bunch of ideas #
But, if you know of a solution I don't, feel free to drop an issue. I will not be taking pull requests.
CSS Component library #
A collection of HTML and CSS snippets to make it easier to say "fuck you" to their Javascript-dependant equivalents (they're evil).
Example:
<m-flex direction="column" wrap grow="2" >
<img src="apple.png" />
<img src="pear.jpg" />
</m-flex>
<=>
<style>
.container {
display: flex;
flex-direction: column;
flex-wrap: wrap;
flex-grow: 2;
}
</style>
<div id="container">
<img src="apple.png" />
<img src="pear.jpg" />
</div>
And in case anyone's saying "isn't this just Tailwind with extra steps?", no. If anything it's Tailwind with less steps.
I thought this would be extremely easy to implement but apparently;
Note: The
attr()function can be used with any CSS property, but support for properties other thancontentis experimental.— mdn
>😦
And by "experimental", they meant it doesn't even work in chrome, so any utility-type custom elements isn't possible without JS. Also, with type() breaks when putting it in content, so you can't even debug it.
Nevermind, I did some more testing and apparently you just have to make sure the type is set correctly... and the types supported may be limited? Idk I need more testing on this.
PreHTML / BwtterHTML #
I the hindsight of web standards, some early design decisions seem to make much sense, but they stick around anyway because of the promise of an ever-lasting web and no breaking changes (and we know how well that goes, don't we C++?). This technology may not be necessary yet, but at some point it will be a serious question whether we invent a new protocol for the web (or a new international network [Hi, Yggdrasil!]), break the sacred promise, or we do something in-between where we invent a new standard and translate it to something that the "modern" web browsers understands.
A HTML pre-processor / alternative markup language to make editing files less of a pain - extensible enough to be useful for beginners and veterans alike. Default behavior is to do nothing if no rules are provided, but I'll be sure to supply an example that I deem reasonable.
Examples:
<div /><div>content</div>should resolve to<div></div><div>content</div>. Instead, any/in front of a>is completely ignored and browser leniancy takes it from there and auto-closes the div at wherever it feels is a good spot.<style src="style.css" />instead of<link rel="stylesheet" href="style.css" />for simplicity and consistency with<script>- Resolve custom elements to spec-complient names, eg
<flex>will be resolved to<m-flex>or whatever prefix you prefer (CSS files may or may not be considered, but it's a simple find+replace anyway, I'm sure you'll figure it out)
LiveSVG #
A vector graphics editor that more closely aligns with readable SVG elements/ducuments. Inspired by desmos (which I love using, but the export system is kinda meh), vscode-sqlite3 editor, Godot (specifically the inspector) and figma (I guess).
It will have an interface for creating elements and tweaking them by adding & modifying its property valuess: it'll support straight insertions, values interpreted and translated by the engine abd a more intuitive process (like having an list of instructions for complex paths instead of forcing the user to remember all the commands and which position maps to which argument)
It'll use some sort of template engine (if I make my own I'll call it BetterSVG (obviously)) under the hood, which you could use directly if you wanted to. The goal is kinda that you wouldn't want to, but I digress.
MAML / mYAML / Modular YAML #
Ok, can we all agree that the full YAML spec is... A bit crazy?
- We have a
nokeyword that is equivalent tofalse, but noyeskeyword. And it doesn't help thatnois also the standard abbreviation for Norway / Norse. - Nobody nor their mother is declaring their YAML types explicitly with
!!type(egtext: !!str 42) - only reason anyone would do that is if they're in lining binary data with base64 encoding in a text document likely encoded in unicode. Not particularly efficient if you ask me. Might as well bundle it with the data you actually want and store the filename instead... - Multiple documents in a single file has never been a good idea.
- If you didn't know, YAML has pointers. If you need pointers in your config file, look into relational databases and SQL.
Are these features completely useless? No, they have their time and place, but the point is that most people never use ~80% of the yaml spec (src: I made it the fuck up)
So what if we could just easily create a YAML-like data storage language to only use functionality we actually use and maybe even customize behavior to something more sensible?