A cynical view of the legal profession is that, "The law exists to create more law". Every licensed lawyer will attest to the veracity of that pithy statement. The analogous statement in #IT is this:
"#JavaScript—the language, the ecosystem, the coders, the lot—exists to create more JavaScript versions, more frameworks that repeat the same things, and and more jobs that do the same things."
Every currently-active #programmer will attest to the veracity of this not-so-pithy statement.
Object.assign() is... alright, but it's really weird that there's no #JavaScript Object.merge() so that merging { a: 1, b: { c: 3}} and { b: { d: 4 }} becomes { a: 1, b: { c: 3, d: 4 }} instead of just blind-overwriting "b".
Est-ce qu'une bonne formation JS finançable avec son #CPF, ça existe ? Je suis pas très convaincue par rapport à ce que je vois sur le site Mon compte formation :/
Sometimes I'm quite amazed by my own code
The RTL work last year was quite insane https://mastodon.social/@cheeaun/112932794480750449
There are a number of useful little functions in node:util besides util.inspect() that I’m only just familiarising myself with after admittedly rolling my own versions for a number of them. Hmm, should’ve read through this documentation page more carefully sooner.
e.g., util.deprecate(), util.diff(), util.debugLog(), util.isDeepStrictEqual(), etc.
New Kitten release
• Fixes #236¹: The data preview pages in Kitten’s settings how handle circular references in the deserialised data (which may contain your custom classes if that’s what you were persisting in the database).
PS. Those pages are very rudimentary at the moment and are good for getting quick visual overview of the data you’re persisting. For a fully interactive view, use Kitten’s interactive shell (REPL)² to explore your data until I’ve had a chance to implement a more comprehensive visual interface.
PPS. You persist data in Kitten using the built-in JavaScript Database (JSDB)³ (Or, of course, you can install and use any other database.)
¹ https://codeberg.org/kitten/app/issues/236
² https://kitten.small-web.org/reference/#kitten-s-interactive-shell-repl
³ https://codeberg.org/small-tech/jsdb#javascript-database-jsdb
#JavaScript iterator helper methods (*) – which notation for creating an iterator do you prefer (if you know that method .values() is available)?
set.values().filter(x => (x % 2) === 0)
Iterator.from(set).filter(x => (x % 2) === 0)
Threat actors misuse Node.js to deliver malware and other malicious payloads
Since October 2024, threat actors have been leveraging Node.js to deliver malware and payloads for information theft and data exfiltration. A recent malvertising campaign uses cryptocurrency trading themes to lure users into downloading malicious installers. The attack chain includes initial access, persistence, defense evasion, data collection, and payload delivery. The malware gathers system information, sets up scheduled tasks, and uses PowerShell for various malicious activities. Another emerging technique involves inline JavaScript execution through Node.js. Recommendations include educating users, monitoring Node.js execution, enforcing PowerShell logging, and implementing endpoint protection.
Pulse ID: 67fec5ac1e94a608250d9aa2
Pulse Link: https://otx.alienvault.com/pulse/67fec5ac1e94a608250d9aa2
Pulse Author: AlienVault
Created: 2025-04-15 20:46:36
Be advised, this data is unverified and should be considered preliminary. Always do further verification.
After spending days on this, I finally found this site which gives a simple and concise method of encoding/decoding Unicode strings in #JavaScript to and from #base64
https://base64.guru/developers/javascript/examples/unicode-strings
Next Level CSS Styling for Cursors, by @vale.rocks (@csstricks):
#ReleaseWednesday — I just released a new version (v8.0.0) of https://thi.ng/vectors, an almost complete rewrite of the package with all of its ~900 vector operations. I've updated the Readme with a section of _potentially_ minor breaking changes, however I expect this to be a seamless upgrade for the vast majority of users...
I've recently written more about the reasons and implications of this update and I'll refer you to those posts instead of repeating them once more (see links below).
Just the top-level changes:
- Replaced dynamic code generation with higher-order templating to be usable with strict content security policies (when deployed online)
- New structure allows for vast majority of functions to have doc strings (and they do now)
- More consistent/less confusing naming for some operations
- Potentially improved tree-shaking and smaller project bundle sizes
Related to this update I've also refactored and fixed some bugs in other packages (e.g. color, geom, matrices). As a result both the color & matrix packages are now also free from dynamic codegen and therefore won't cause any problems with strict CSPs
Should you run into any issues regarding this update, please get in touch (also grateful for any other experience/impact reports... )
More info in these recent posts/threads:
- https://mastodon.thi.ng/@toxi/114296442006935718
- https://mastodon.thi.ng/@toxi/114319651778770391
- https://mastodon.thi.ng/@toxi/114336012068839250
Happy coding!