Nick Melms
sudonomad.bsky.social
Nick Melms
@sudonomad.bsky.social
In JavaScript arrays are objects, and objects are passed by reference! This means that a reference to the memory location is passed instead of the actual value. Changes made to one variable can affect another if they point to the same object.

#JavaScript #webdev #fundamentals
December 30, 2024 at 3:45 PM
Shit, arrays are objects.

#javascript
December 18, 2024 at 1:04 AM
Digging into higher-order functions a bit more. Starting to see how much I skipped over when I first learned these. There's a lot more to them than just using map and filter.

#JavaScript #WebDev
December 17, 2024 at 1:40 AM
Never realized the callback in higher-order functions like .map, .reduce, and .filter that contain additional parameters such as the index and the original array.

For example, if you wanted to only add up even indices, you could do something like this:

#JavaScript
December 15, 2024 at 5:44 PM
Need a dynamic grid of elements with only internal borders? Check out this CSS trick using pseudo elements instead of borders. It's flexible and pretty easy.

blog.nickmelms.dev/blogs/css-bo...
Dev Blog
Astro description
blog.nickmelms.dev
November 21, 2024 at 10:29 PM