TIL (about the Dark Arts of HTML)
-
@boomzilla said in TIL (about the Dark Arts of HTML):
@sockpuppet7 said in TIL (about the Dark Arts of HTML):
things
What is that thing being cut?
it's a package that had a faucet, I'm not sure the right word for it
edit: this is close enough
-
Apparently a default image for Person in Outlook (and likely elsewhere) is memorializing a funny arrest.
-
-
@boomzilla I love the apparent trend of giant sloths. Did you know avocados are also not the result of giant sloths?
-
TIL: When using Midnight Commander to copy shit to a remote destination, it will first copy to
/tmp
and then do the actual copy.It has a bug report from 15 years ago.
One can only imagine why it hasn't been fixed yet.
-
@Tsaukpaetra said in TIL (about the Dark Arts of HTML):
One can only imagine why it hasn't been fixed yet.
I know:
-
@TimeBandit said in TIL (about the Dark Arts of HTML):
@Tsaukpaetra said in TIL (about the Dark Arts of HTML):
One can only imagine why it hasn't been fixed yet.
I know:
Nah, it’ll be because changing it will break someone’s workflow. Like “omg you can’t use MC to copy a file I’m working on because write contention (or some other random ass-pull answer) so you better copy it to tmp first”
I don’t know exactly what weird-ass workflow it would be but that’ll be the reason it originally started out copying to tmp first and whoever made it that way won’t want to change it.
-
TIL the hamburger menu turns into a spinner. When you click it.
-
@Tsaukpaetra said in TIL (about the Dark Arts of HTML):
TIL: When using Midnight Commander to copy shit to a remote destination, it will first copy to
/tmp
and then do the actual copy.It has a bug report from 15 years ago.
One can only imagine why it hasn't been fixed yet.
I'm noticing the bug report mentions FISH, the FIles over SHell plugin. It is a “virtual filesystem” plugin that allows accessing files over any remote shell. I remember it's author showing it to me back then 25 years ago. At the time it had the benefit that unlike scp, this worked also over rsh and telnet (that were on the way out, but still in some use) and I suppose you could use it now e.g. over serial line when working with some embedded box.
In MC, it is a “vfs” plugin. And IIRC (I rewrote one from shell to C back then, but it's been 25 years, I don't remember the details) the interface is designed to make it as easy as possible to write them, and that means the data are passed over temporary files. Changing that would mean rewriting the whole subsystem, so no wonder it wasn't done.
-
TIL there's a random ass tiny uninhabited island in the middle of Pacific, some 120 nautical miles northwest of Kiribati, that will grant your child US citizenship if you give birth there.
-
@Gustav said in TIL (about the Dark Arts of HTML):
will grant your child US citizenship
You want your kid to get killed in a school shooting?
-
@TimeBandit even the tiny island 120 nautical miles northwest of Kiribati knows where the Garage is
-
@Gustav If it's uninhabited then who's doing the granting?
-
@Watson said in TIL (about the Dark Arts of HTML):
@Gustav If it's uninhabited then who's doing the granting?
If it's the case I'm thinking of, the island in question happens to be a part of the US territorially. And the US grants anyone born in their territory (with some exceptions around certain Territories like American Samoa) citizenship by the doctrine of jus solis and the 14th Amendment.
So it just happens to be a very far-distant piece of the US, but otherwise behaves like any other US possession.
I'm curious whether children born in US embassies in foreign countries count as citizens...ok, google says no. They're not literally US territory, they're just under diplomatic protection by international law. Same with US military bases in foreign countries.
Edit: American Samoa is weird--people there are U.S. nationals but not U.S. citizens. And entry is controlled by American Samoa, not US Citizenship and Immigration Services. Even US citizens need to either have proof of employment in A.S. or a ticket onward within 60 days to enter the country, similar to any other foreign national.
-
@Benjamin-Hall said in TIL (about the Dark Arts of HTML):
So it just happens to be a very far-distant piece of the US, but otherwise behaves like any other US possession.
That's the thing, it doesn't. Every other overseas possession of the USA is either inhabited and people are US citizens (with the exception of American Samoa), or is uninhabited and birthright citizenship does not work (e.g. the famous Midway Islands). Palmyra Atoll, a 11.9 km2 (4.6 sq mi) speck of land in a literal middle of nowhere, is the only territory in the entire history of United States that holds the incorporated unorganized territory status.
-
This seems relevant.
-
@Zecc entered the some 80 years ago, and was later expelled.
wants to enter the .
Take care!
-
-
adjective Having the same mother and father; a full (brother or sister).
adjective Being born to one’s blood aunt or uncle, a first (cousin).
adjective obsolete Closely related, akin.
noun obsolete A near relative.
-
-
@boomzilla's onebox said in TIL (about the Dark Arts of HTML):
the reason you "smell" it might surprise you
Given how little it snows here, it definitely would surprise me...
-
@dkf if I smelled it I’d be doubly surprised. Firstly I live near the sea in Brighton, snow is rare enough here.
Secondly I am in that camp of people that has always been completely anosmic.
-
-
Was bored and nostalgic.... so i whipped up this lovely thing.
very fun to full screen browser instances across all your monitors and call someone over to take a look at this weird thing your PC is doing.
okay so it's far more dark arts of javascript than HTML but it's in an HTML file so i'll let it pass.
now i wonder if i can do a similar thing to make it play white noise like i remember from childhood.....
-
@accalia said in TIL (about the Dark Arts of HTML):
Was bored and nostalgic.... so i whipped up this lovely thing.
very fun to full screen browser instances across all your monitors and call someone over to take a look at this weird thing your PC is doing.
okay so it's far more dark arts of javascript than HTML but it's in an HTML file so i'll let it pass.
now i wonder if i can do a similar thing to make it play white noise like i remember from childhood.....
oh... BOOOOO! the CSP settings on this site block the script if you click that link,....
fiiiine...
<!DOCTYPE html> <html> <head> <title>NTSC Snow</title> </head> <body style="position: absolute; top: 0; bottom:0; left: 0; right:0; margin:0; overflow:hidden"> <canvas id="snow" style="width: 100%; height: 100%;object-fit: fill;" width="480" height="320"></canvas> <script type="text/javascript"> setTimeout(() => { const snow = document.getElementById('snow') const ctx = snow.getContext('2d') const numValues = 480*320 setInterval(() => { let toFetch = numValues; let data = [] while (toFetch > 0){ const tmp = new Uint8Array(Math.min(65536, toFetch)) crypto.getRandomValues(tmp) data = data.concat(Array.from(tmp)) toFetch -= tmp.length } const img = ctx.getImageData(0, 0, 480, 320) let dot = 0 for (let i = 0; i < numValues; i++) { const offset = 4 * i img.data[offset] = data[i] img.data[offset + 1] = data[i] img.data[offset + 2] = data[i] img.data[offset + 3] = 255 } ctx.putImageData(img, 0, 0) }, 33) }, 250) </script> </body> </html>
edit => remove old bitmasks from development that don't get used as 1 bit snow looks wrong
-
-
@TimeBandit said in TIL (about the Dark Arts of HTML):
@accalia said in TIL (about the Dark Arts of HTML):
Snow.html
Thanks but no thanks
not that kind of snow. :P
-
@accalia You made me copy the code, save it to a file, then open that file in a browser.
You should be proud
-
@TimeBandit said in TIL (about the Dark Arts of HTML):
@accalia You made me copy the code, save it to a file, then open that file in a browser.
You should be proud
i'm impressed. kneeling warthog is proud. curiosity must have been stronk.
-
@accalia said in TIL (about the Dark Arts of HTML):
curiosity must have been stronk.
Just remember what happened to the cat.
-
@HardwareGeek said in TIL (about the Dark Arts of HTML):
@accalia said in TIL (about the Dark Arts of HTML):
curiosity must have been stronk.
Just remember what happened to the cat.
It got eaten?
-
@Tsaukpaetra No, it had an encounter with a Mars rover.
-
https://www.google.com/search?hl=en&q=Chicxulub
By which I mean the animation over the page.
-
@accalia said in TIL (about the Dark Arts of HTML):
setTimeout(() => { /* * */ setInterval(() => { /* * */ }, 33) }, 250)
Wait, what?
-
@Zecc I suppose the outer
setTimeout
is just to make the actual initialization run from the event loop after whatever other initialization happens. Could have probably been put into body.onload instead, but this works, so meh.
-
@Bulb I’m assuming this is a poor man’s DOMContentLoaded hack rather than an onload one… but yeah, likely.
-
@Bulb Right. For some reason I thought of the setTimeout body as running multiple times.
I should have figured @accalia as not posting a
forktimeout bomb. But I don't think I was applying enough brain cycles there.
-
-
@Zecc said in TIL (about the Dark Arts of HTML):
@accalia said in TIL (about the Dark Arts of HTML):
setTimeout(() => { /* * */ setInterval(() => { /* * */ }, 33) }, 250)
Wait, what?
yeah. i was a derp and forgot about body.onload so i used a short timeout to set the interval. it works. and is shockingly performant, unless you're trying to record your screan as that makes just about any video coded dump core into its pants having to deal with "pure" random
really if i had more spoons i'd have done the whole thing requesting proper animation frames so the processing time of the image would be taken into consideration when targeting 29.975 frames per second..... instead of just setting 33ms interval and calling it good. but.... :kneeling_fox.png:
-
@Arantor said in TIL (about the Dark Arts of HTML):
@Bulb I’m assuming this is a poor man’s DOMContentLoaded hack rather than an onload one… but yeah, likely.
… and I looked up
DOMContentLoaded
and that suggested that the easiest option is to just adddefer
attribute to thescript
element. That makes the script run after the DOM (but not external resources) is loaded, and just before theDOMContentLoaded
event is emitted.
-
The wonderful world of JavaScript.
-
@Arantor said in TIL (about the Dark Arts of HTML):
The wonderful world of JavaScript.
there's so many ways to do what can be done, no one ever stops to ask if it should be done. :D
-
@accalia when I do sit and write JS, I like that I have so much flexibility available to me, but at the same time I also completely hate it.
-
@Arantor said in TIL (about the Dark Arts of HTML):
@accalia when I do sit and write JS, I like that I have so much flexibility available to me, but at the same time I also completely hate it.
agreed. and i preferentially code in JS for fun! :D
-
@accalia said in TIL (about the Dark Arts of HTML):
agreed. and i preferentially code in JS for fun! :D
At least better than my colleague who codes in PHP for fun.
-
@accalia said in TIL (about the Dark Arts of HTML):
@Arantor said in TIL (about the Dark Arts of HTML):
The wonderful world of JavaScript.
there's so many ways to do what can be done, no one ever stops to ask if it should be done. :D
And then they forget all of them and invent a new way it can be done.
-
@Watson said in TIL (about the Dark Arts of HTML):
And then they
forget all of them andbecause NIH invent a new way it can be done.FTFY
-
@Watson said in TIL (about the Dark Arts of HTML):
@accalia said in TIL (about the Dark Arts of HTML):
@Arantor said in TIL (about the Dark Arts of HTML):
The wonderful world of JavaScript.
there's so many ways to do what can be done, no one ever stops to ask if it should be done. :D
And then they forget all of them and invent a new
way it can be doneshape with non-zero amount of vertices supposedly facilitating transportation of goods in a particular way.
-
@Applied-Mediocrity said in TIL (about the Dark Arts of HTML):
@Watson said in TIL (about the Dark Arts of HTML):
@accalia said in TIL (about the Dark Arts of HTML):
@Arantor said in TIL (about the Dark Arts of HTML):
The wonderful world of JavaScript.
there's so many ways to do what can be done, no one ever stops to ask if it should be done. :D
And then they forget all of them and invent a new
way it can be doneshape with non-zero amount of vertices supposedly facilitating transportation of goods in a particular way.It goes in the square hole?
-
@Atazhaia said in TIL (about the Dark Arts of HTML):
@accalia said in TIL (about the Dark Arts of HTML):
agreed. and i preferentially code in JS for fun! :D
At least better than my colleague who codes in PHP for fun.
Remind me again which language has enforceable type safety as a core feature.