kaiserkiwi, (edited ) to programming German
@kaiserkiwi@corteximplant.com avatar

: All of the major browsers include $() and $$() convenience methods. (Like in jQuery back in the days)

$() replaces document.querySelector()
$$() replaces* document.querySelectorAll()

And it has pretty robust browser support:
https://caniuse.com/dom-manip-convenience
If you don’t care about IE or Opera Mini you should be fine. And in nearly no project anyone cares about these two anymore. (But for Opera Mini you should definitely check your target audience!)

  • The $$() method returns an array (not a NodeList like the Element.querySelectorAll() method) of matching items.
kaiserkiwi,
@kaiserkiwi@corteximplant.com avatar

Follow up because I never researched this topic but was always just confused about NodeLists 😅

NodeLists vs. Arrays
https://gomakethings.com/nodelists-vs-arrays/

In Short, aren't a Feature it's an language agnostic Browser API. 🤯 querySelectorAll() and getElementsByTagName() aren’t JavaScript methods either. 🤪

I love how I use JavaScript for about 17 years now and still learn new/old things about it. ^^"

laimis, to random
@laimis@mstdn.social avatar

I don't care what anyone says, and is a match made in heaven. It's like having an assistant at your side that's available 24/7 and knows the most obscure crap imaginable.

futurebird, to programming
@futurebird@sauropods.win avatar

Did you know in python you can stick a for loop in the list brackets and just BAM have a list? No “append” check it:

l=[chr(i+65) for i in range(0,26)]
print(l)

> [‘A’, ‘B’, ‘C’, … , ‘Z’]

(it will be the letters A-Z since the unicode for the capital letter starts at 65, chr renders these numbers as letters.)

Is that classy? For some reason this neat little feature isn’t really taught. I guess with a loop and appending you have not flexibility— but still this is cool.

mjgardner, (edited ) to programming

“It has to run on 5.8” is like saying, “It has to run on XP”

@Perl

LouisIngenthron, to random
@LouisIngenthron@qoto.org avatar

Important note for / , especially :

tools like can impressively improve productivity, but before using them, check with your employer/client first! Every client I've reached out to about this has wanted to run it past their legal department first (which is a really smart move on their part!).

DO NOT, under any circumstances, allow these tools to send client/employer data to the AI vendors (which is necessary for their operation) without getting client/employer consent first.

This will be a core tenet of for enhancing their services with AI assistants, so best get in the habit now.

questlog, to programming
@questlog@mstdn.games avatar

For anyone that wondered why Questlog only links to YouTube videos like game trailers and doesn't just embed the No Cookie version.

There are many reasons but one of the biggest reasons was the privacy philosophy of Questlog. But didn't I say No Cookie version? Yes, but it is not what you expect.

This post describes it pretty well. https://cloudfour.com/thinks/youtube-no-cookies-adds-cookies/

I realized that at work a while ago and decided I don't want to use YouTube-Embeds ever again.

mjgardner, to programming

We will eventually have a local package repo cache, but not today.

( excuse via https://xkcd-excuse.com)

salvari, to photography

Hi all!
I've just joined Calckey to learn new ways. I've been using Mastodon for some time.

Incomplete list of interests:

mjgardner, to programming

59 years ago today, the first computer program written in was run.

The easy-to-learn and -use language revolutionized . A decade later, would co-found to develop and sell the BASIC interpreter for the 8800, the first commercially successful desktop microcomputer.

More from when celebrated BASIC’s fiftieth anniversary: https://www.dartmouth.edu/basicfifty

mjgardner,

@bazcurtis @Cloudguy Classic from the and before was thought to nearly ruin first-time programmers, robbing them of the ability to write well in other . http://catb.org/jargon/html/B/BASIC.html

I first learned it as a child on the PET and . Does that say anything about the current quality of my ? At least I don’t pine for line numbers, GOTO and GOSUB.

anatudor, to programming
b4nq, to linux

post v2.0

I'm Kuba, interested in :arch_linux: :programmer: and , but also 🍛 and . I use he/him pronouns. I love people :QueerCat_Bisexual:

Aspiring pirate 🏴‍☠️ who is exploring his way of being , looking for a people who are full of positive energy and trying to give them the same :blobcatheart:

I toot/boost various things in 🇬🇧 and 🇵🇱.

If u wanna talk:
matrix: @b4nq:matrix.org
discord: b4nq#5431

Random hashtags go:

questlog, to gaming
@questlog@mstdn.games avatar

Hi there!

I just pushed a little performance update. If you want to learn more about this feature and a bit about the future of updates for Questlog, you can read my short post on Ko-Fi:
https://ko-fi.com/Post/Small-update-on-images-Z8Z2KW1YT

mjgardner, (edited ) to programming

If you want to mess with , occasionally insert things like the following into web forms:

’

[object Object]

Stormeko, to webdev

Anyone good with HTML and CSS that can tell me why one of my pages have a gap and the other doesn't? It happens because of the backstory bit, but I don't see anything wrong?

Page with the gap https://stormeko.neocities.org/OCs/Tangle

Page without the gap https://stormeko.neocities.org/OCs/Dakota

Ellopunk, to programming

Hi everyone. Would you all be willing to share your favorite resource for learning Right now I’m using code academy and am currently learning functions.

TicklishHoneyBee, to gamedev

While clearing out some messy directories on my laptop, I stumbled upon this old gem:
From that time I was working as a sysadmin, got bored, and wrote a solitaire game to play on the console.

mjgardner, (edited ) to programming
anatudor, to programming

How would you code this sort of outset gradient border with:

❌no JS
⚠️only 1 img element
❌no magic values for the gradient stops, they're obtained from img source
⚠️no SVG, no images in general other than the actual image & the border one

Image examples 👇

Example image #1.
Example image #2.
Example image #3.

damngoodtech, to programming
@damngoodtech@mastodon.social avatar

You know those times when you're working on a or project and you forget what port a service is on?

There's a site just for that: https://whatport.net

Bookmark the page, refer back to it whenever you need to refer to a port number.

Includes a copy feature for

8bitworkshop, to random

🆕 8bitworkshop 3.10.1 is out! This update includes: atari-vector music fix, 6502 metadata fixes, c64 & atari8 preset fixes, atari5200 menu item added, github delete repo fix & more! 🕹️

https://8bitworkshop.com

8bitTim, to programming

A little quality time with this grand old lady.
-80

emanaton, to php

Sometimes you just have be honest about what you've done.

maxim, to programming
@maxim@mastodon.gamedev.place avatar

I love programming...

I've been doing it for 20 years, but every time there is a moment when you come across a bunch of code that you wrote a long time ago and you don't want to touch it anymore so as not to break it, and you look for a solution for half a day, and then you add one line and everything is fine

:unity:

video/mp4

  • All
  • Subscribed
  • Moderated
  • Favorites
  • megavids
  • kavyap
  • DreamBathrooms
  • thenastyranch
  • magazineikmin
  • InstantRegret
  • GTA5RPClips
  • Youngstown
  • everett
  • slotface
  • rosin
  • osvaldo12
  • mdbf
  • ngwrru68w68
  • JUstTest
  • cubers
  • modclub
  • normalnudes
  • tester
  • khanakhh
  • Durango
  • ethstaker
  • tacticalgear
  • Leos
  • provamag3
  • anitta
  • cisconetworking
  • lostlight
  • All magazines