A Little Loopy - Arrays, Loops, forEach, some, for...of, for - FrontEnd Engineering Explained #js
A Little Loopy - Arrays, Loops, forEach, some, for...of, for - FrontEnd Engineering Explained #js
Folks who #website: I'm trying to create a slice'n'dice-able #data #table -- somewhat like https://instances.vantage.sh/ with the per-column client-side search/constraint/etc. FWIW my data's a discrete JSON file.
I'm allergic to JavaScript insofar as I have zero idea what I'm doing with it (and *can't* do anything with it, myself) but will happily copy'n'paste it as needed.
Got any pointers? #websites #HTML #datadriven #javascript #js #webdev #WebDesign #WebDevelopment #dataviz
Se ois kuulkaas rekryhommat auki Fennoalla.
Etsin softatiimiini kahta hyvää tyyppiä, 1x mid- ja 1x senior-devaajaa. Perustaitoina tulisi olla PHP ja JS, mutta erityisesti sennun kohdalla kaipaan taitoja myös siitä koodin yläpuolelta. Sisartiimiin etsitään myös yhtä senior-devaajaa.
1/4
(Kaikki buustaukset tervetulleita!)
Somebody into Svelte? What UI kit/framework do you use?
Framework7 have an issue with svetle5 so looking for alternative. Thank you
So I should re #introduce myself; used to host my own instance at artemai when that was a thing; decided to get back on Mastodon again because the rest of social is a dumpsterfire.
I'm a #UNIX sysadm originally (from the late 90s) but started using #Linux in 91, bringing early
dialup internet to #Newcastle with community group hunter #apana.
I'm a #coder, #python is the go-to language these days, some #js but plenty of #C and some #golang too.
Ten years ago I landed in #liveevents and #visionswitch / #camera #direct #sports presentation in major
#stadiums along with building software for data-driven #content for use in those environments.
I'm a #ham radio operator. Callsign VK2WAY. I'm mostly interested in signals processing and digital communications.
I used to officiate #RollerDerby but have streamed it since 2014 as Downunder Derby TV. I still manage socials for and help co-ordinate Queer Roller Derby - @queerderby.
I'm #queer #pansexual
#poly
#nonbinary
and use they/them pronouns.
New Kitten release
• Now leaves <style> tags within <template> tags alone when collating and normalising the CSS on a page so as not to interfere with scoped styles in declarative shadow DOM.
(Kitten’s Streaming HTML workflow¹ – which uses htmx and WebSockets under the hood – combined with built-in support for slots, etc., in Kitten components² means the use of declarative shadow DOM is mostly useful if you want scoped styles. Ideally, of course, use classes to scope styles to your components and be specific in your CSS selectors in general so as not to pollute elements in your components. Although that’s a bit like saying you should floss everyday. Yeah, we all know we should…) :)
Update: All that said, I’d highly recommend you don’t use Shadow DOM in your Kitten apps. For one thing, htmx’s WebSocket extension doesn’t seem to play well with it. And for another, you really don’t need it and definitely not just to get scoped CSS.
Enjoy!
¹ https://kitten.small-web.org/tutorials/streaming-html/
² https://kitten.small-web.org/tutorials/components-and-fragments/
New Kitten release
• Socket routes now have precendence in the router.
This stops wildcard page routes from capturing the default socket routes that Kitten creates to enable the Streaming HTML workflow.
e.g., Previously, the following route:
/videos/index_[slug].page.js
Could not connect to its default socket (/videos/default.socket) because default.socket would be captured by the [slug] parameter.
Now, it will work as intended as the /videos/default.socket (a socket route) has precendence over index_[slug].page.js (a page route).
Learn more about Kitten’s Streaming HTML workflow here:
https://kitten.small-web.org/tutorials/streaming-html/
Enjoy!
Is there any way in HTML / JavaScript to configure the language of native form validation messages?
The browser (at least my Firefox) seems to display the labels in the preferred language that I configured in the settings, but on some website I might have configured another language at the website level (different from my Accept-Language header), and it looks super weird to have a webpage in French but form validation messages in English.
@leaverou I've been using #JS generators in my `showModalDialog` polyfill (see the source): https://niutech.github.io/showModalDialog/demo.html
If you have dozens (or more!) third-party scripts on a page, it can be tricky to find the source of your #webperf pain. This guide covers how to:
Audit the scripts on your pages
Understand third-party performance metrics
Prevent regressions
Make your third-party providers accountable
https://www.speedcurve.com/web-performance-guide/third-party-web-performance/
--- NEW BLOG POST ---
In defense of the for...of loop
Despite its introduction in ES2015 and implementation in all browsers over 8.5 years ago, I still see .forEach used in favor of the modern for...of loop. [...]
Also, inspired by this post by @rauschma I made the Navigation menu toggle in mobile/narrow viewports work without JS. Neat!
https://fosstodon.org/@rauschma/114099045695366948
However to make it more accessible I set aria-expanded to true or false, which you can't do with CSS. So I had to use JS for that. So JS is a requirement for accessibility apparently.
"We’re gambling that the velocity gain from this new tool will not be lost to its maintenance burden"
this is it, folks! we are in the final week before submissions are due for GOOD INTERNET, a new print periodical magazine about all the things that make the #web fun: things like the #smallweb, the fediverse, the #indieweb, and efforts to actively fight #enshittification. submissions are open until MARCH 15.
check the submission guidelines or sign up for email alerts to be notified when we publish in may!
https://goodinternetmagazine.com
if this is your first time hearing about this, you still have enough time to come up with and write an article or complete a digital #art piece, if you're passionate about the #internet and want to write about it! :) bloggers, it's your time to shine!~
i can't wait to show y'all the incredible stories that have been submitted from all over the 'net, and some of the coolest art i've seen about the web!
thank you to everyone who's been so supportive of this project already. this is why this side of the internet is amazing. please boost, if you can; i want to make sure i did everything i could to include as many diverse voices as i can.
thank you!
original post: https://tilde.zone/@xandra/113913277766098384
Using LLM AI to unminify JS code? ... oh yes
https://glama.ai/blog/2024-08-29-reverse-engineering-minified-code-using-openai
Can Cro be used to stand up a simple website? I know zero JS and negligible CSS. I'm mostly a Raku and Perl guy who is 100% on the back end. At minimum I need a primer for basic JS, CSS forms, and likely Cro or #Dancer.
The site will send text and hashes to and from the back end and manage a modest number of users with their own accounts. Message forms need to look nice on the front end. This is for a ham radio project of mine.
ich glaube ich sollte mal schauen wie ich das activitypub Protokoll in meine Applikationen die mir so vorschweben einbauen kann.
Eigentlich sollte es doch dafür bestimmt was für Python oder JS geben.
#activitypub #python #js #bibliothek
mal eine Frage an die Coder hier im Netz.
Ich bin auf der Suche nach einem js Modul welches mir in "Echtzeit" meinen Markdown Code umsetzt wenn ich die Zeile wechsel.
Also nicht in einem neuen Fenster sondern im gleichen Textbereich in dem ich gerade schreibe. Ähnlich wie dies zum Beispiel ein Marktext macht. (nur halt im Web)
#js #markdown #editor #online #selfhosting
Pleased to be sneaking some #ProgressiveEnhancement into the #DesignSystem we're building at Investec.
Currently making an Accordion component using #HTML <details> & < summary>, which requires zero client-side #JS. Until #interop2025 brings ::details-content support to Firefox & Safari, the opening / closing won't be animated in those browsers. But, we're cool with that. It's still perfectly usable without animations.
10 Cool CodePen Demos from February 2025
https://alvaromontoro.com/10-cool-codepen-demos/2025/02/
An homage to Studio Ghibli, custom ranges, web components, web games, CSS art, mix blend modes showcases... and more!