Minichan

Topic: I recently found out JavaScript has a .toHex() function

Handsome Squidward started this discussion 1 month ago #135,762

I’m sorry, I know you all don’t care.

new TextEncoder().encode(str).toHex()

YOU’RE TELLING ME CONVERTING UNICODE INTO A BASE 16 ENCODED HEX STRING IS A ONE LINER AND DON’T HAVE TO WRITE SOME Array.from() bs to convert the Uint8Array into an array so I can use .map and return a string type instead of a uint8 from the callback function and then do some bs with .padStart() I forget which argument is the number and which is the string.

It’s so beautiful 🥹

Handsome Squidward (OP) double-posted this 1 month ago, 5 minutes later[^] [v] #1,442,297

🙏

https://tc39.es/ecma262/multipage/indexed-collections.html#sec-uint8array.prototype.tohex

Handsome Squidward (OP) triple-posted this 1 month ago, 34 minutes later, 39 minutes after the original post[^] [v] #1,442,301

You’ve gotta love JavaScript. One of the world’s most popular languages still missing basic features in 2026. For example, it used to be for years it didn’t have a module import system. They added one. Nice. How do you package it?

You need 3rd party tools. 🥳

Node JS doesn’t count. I mean, the language itself. It has no system for packaging modules. This is one of the most popular languages in the world. It has no built in system for packaging modules into a single file.

Anonymous B joined in and replied with this 1 month ago, 4 hours later, 4 hours after the original post[^] [v] #1,442,309

boof joined in and replied with this 1 month ago, 3 hours later, 7 hours after the original post[^] [v] #1,442,321

I hate it when sites use it for making navigation buttons and you can't even access something like page 77 in a 400 page sequence without clicking available buttons that only skip a handful of pages at a time, and even manually changing the URL to get to the desired page doesn't fucking work

Anonymous D joined in and replied with this 1 month ago, 3 hours later, 11 hours after the original post[^] [v] #1,442,365

I miss Web sites with frames. I really miss Web sites with open directories that allowed one to helpfully upload content, hypothetically.
:

Please familiarise yourself with the rules and markup syntax before posting.