JavaScript
32.1K subscribers
1.06K photos
10 videos
33 files
737 links
A resourceful newsletter featuring the latest and most important news, articles, books and updates in the world of #javascript πŸš€ Don't miss our Quizzes!

Let's chat: @nairihar
Download Telegram
πŸ€”34🀣166❀4πŸ‘4
🀟 Runtime Compatibility Across JavaScript Runtimes

Several developers have come together to build this convenient way to visualize the compatibility of different Web APIs and JavaScript features across the ever increasing number of different runtimes (e.g. Bun, Deno, Node, LLRT..)

TOM LIENARD ET AL.

βœ… The item above reminds me of node.green, a visualization of JS feature support across versions of Node / V8, though it is nearly entirely green/Yes these days!
Please open Telegram to view this post
VIEW IN TELEGRAM
❀6πŸ‘54
CHALLENGE ❓


let arr = [1, 2, 3];

function modifyArray(array) {
array.push(4);
}

modifyArray(arr.splice(1));
console.log(arr);
Please open Telegram to view this post
VIEW IN TELEGRAM
12πŸ€”6🀩5πŸ‘2
What is the output?
Anonymous Quiz
6%
[]
21%
[1]
60%
[2,3,4]
13%
[1,2,4]
πŸ€”3128πŸ‘14🀣4
🍊 Atrament 4.0: Library for Smooth Canvas Drawing and Handwriting

A small library for beautiful drawing and handwriting on canvas elements. It’s been around for several years but v4.0 is almost a complete rewrite. GitHub repo.

JAKUB FIALA
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ‘52❀1
CHALLENGE ❓
let x = 5;
let result = typeof (x + "10");

console.log(result);
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ‘4❀3
What is the output?
Anonymous Quiz
26%
number
57%
string
12%
Error
5%
object
❀22πŸ‘9πŸ€”9🀩21
πŸ—£οΈ Why is it called a REST API when it wakes me up at 3 AM to fix it?

Zach Wilson
Please open Telegram to view this post
VIEW IN TELEGRAM
🀣875πŸ€”3🀩2
❓ CHALLENGE

function foo() {
let a = b = 0
a++
return a
}

foo()
console.log(typeof a)
console.log(typeof b)
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ€”22πŸ‘8❀2
πŸ‘247❀2πŸ€”2
Please open Telegram to view this post
VIEW IN TELEGRAM
17❀9
❓ CHALLENGE

const obj = {
a: 1,
b: function() {
console.log(this.a);
}
};
const func = obj.b;
func();
Please open Telegram to view this post
VIEW IN TELEGRAM
❀10πŸ‘61
πŸ€”33πŸ‘1510❀1🀩1
πŸ˜‚
Please open Telegram to view this post
VIEW IN TELEGRAM
🀣98πŸ€”17❀63
❓ CHALLENGE

function* generator() {
yield 1;
yield 2;
yield 3;
}
const gen = generator();
console.log(gen.next().value);
console.log(gen.next().value);
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ‘3❀2
What is the output?
Anonymous Quiz
14%
1, null
24%
1, undefined
52%
1,2
9%
1, 1
πŸ€”22πŸ‘12❀74
🀟 __dirname is Back in Node with ES Modules

In an ES module, instead of using __dirname or __filename, you can now use import.iss.oneta.dirname and import.iss.oneta.filename (this came with Node 20.11.0 (LTS) released in January).

PHIL NASH
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ‘94❀2
❓ CHALLENGE

const a = { a: 1 };
const b = Object.assign({}, a);
b.a = 2;
console.log(a.a);
Please open Telegram to view this post
VIEW IN TELEGRAM
🀣20πŸ€”13πŸ‘11❀77
✌️ Optimizing Javascript for fun and for profit

Interesting benchmarks 🍊

romgrk
Please open Telegram to view this post
VIEW IN TELEGRAM
❀7πŸ‘3πŸ€”11