JavaScript
31.9K subscribers
1.01K photos
9 videos
33 files
697 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
πŸ‘€ PostalMime: A Universal Email Parsing Library

An email parsing library happy in most JS runtimes. Takes the raw source of emails and parses them into their constituent parts.

Postal Systems
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ‘7❀2πŸ”₯1
CHALLENGE

function trickyFunction() {
let a = 5;
let b = '5';
let c = 5;

if (a == b && b === c) {
console.log('Condition 1');
} else if (a === c || b == c) {
console.log('Condition 2');
} else {
console.log('Condition 3');
}
}

trickyFunction();
πŸ‘6πŸ”₯2
πŸ‘27🀣15❀4πŸ€”4πŸ”₯1
πŸ“„ Play Tetris in a PDF File

I'll let you decide if this one is fun or frightening! Whether or not this will work depends on your PDF reader or browser support, but it works with Chrome and Firefox, at least.

The PDF document format supports embedded JavaScript and this experiment uses it to implement a game of Tetris. The developer, Thomas Rinsma, has used Python to output the PostScript that includes the game's JavaScript. Couple that with the fact many browser PDF renderers are themselves implemented in JavaScript (e.g. PDF.js) and you have a veritable Matryoshka doll of technologies at play here.
🀣10πŸ‘6❀2πŸ€”2
CHALLENGE

function displayArguments() {
console.log(arguments.length);
console.log(arguments[0]);
console.log(arguments[2]);
}

displayArguments('Hello', 'World', 'JavaScript', 'Quiz');
πŸ€”8🀣7❀3πŸ‘3πŸ”₯2
🀣23πŸ‘20❀6
πŸ‘ˆ Tagify 4.33: An Elegant Input Component for Tags

The polished demos show a lot of effort has been put in here. GitHub repo.

Yair Even-Or
Please open Telegram to view this post
VIEW IN TELEGRAM
❀4πŸ‘3πŸ”₯2πŸ€”1
CHALLENGE

let str = "Hello, World!";
let result = str.substring(7, 12);
console.log(result);
πŸ‘6
What is the output?
Anonymous Quiz
7%
lo, Wo
12%
Hello
71%
World
9%
, Worl
πŸ‘22πŸ”₯8πŸ€”4🀣4❀2
❄️ The 'WinterCG' Web Interoperable Runtimes Community Group, an effort to promote standards around runtime interoperability of JavaScript runtimes, has moved to Ecma International and is now known as WinterTC (TC55).
❀4πŸ‘2πŸ”₯2
CHALLENGE

const a = '10';
const b = 20;
const c = '30.5';

const result = Number(a) + b + Number.parseFloat(c);

console.log(result);
πŸ‘4❀2
What is the output?
Anonymous Quiz
23%
'60.5'
9%
1020
61%
60.5
7%
3050
πŸ‘24🀣13πŸ”₯7πŸ€”5❀1
🀟 A New Chapter for Express.js

2024 saw the still-extremely-popular Express project awaken from a slumber, of sorts, with work being made to update things to modern standards, a security audit, and the release of Express v5. Here, the team explains what’s been going on behind the scenes to get Express back on the tracks, as well as a β€œbold vision for 2025.”

Express Technical Committee
Please open Telegram to view this post
VIEW IN TELEGRAM
❀11πŸ‘4πŸ”₯2
CHALLENGE

function multiply(a, b = a * 2) {
return a * b;
}

console.log(multiply(3));
πŸ‘10πŸ”₯4
What is the output?
Anonymous Quiz
22%
6
63%
18
10%
12
6%
9
πŸ‘13πŸ€”11❀5πŸ”₯2🀣1
😎 Node Web Audio API 1.0: A Web Audio API Implementation for Node

More accurately, it’s a set of Node bindings for a Rust-powered non-browser implementation of the Web Audio API.

IRCAM – Centre Pompidou
Please open Telegram to view this post
VIEW IN TELEGRAM
❀5πŸ”₯4πŸ‘3
CHALLENGE

class Vehicle {
static type() {
return "Generic Vehicle";
}
}

class Car extends Vehicle {
static type() {
return "Car";
}
}

console.log(Car.type());
πŸ‘11
🀣16πŸ€”8πŸ”₯4❀3🀩2πŸ‘1
πŸ‘€ Learn Yjs and Building Realtime Collaborative Apps in JavaScript

Yjs is a CRDT (Conflict-free replicated data type) library for building collaborative and local-first apps. CDRTs are powerful but can be tricky to β€˜get’ which is why this new interactive Yjs tutorial is so valuable. A great way to learn about building collaborative, syncing webapps from the ground up.

Jamsocket
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ‘4❀2πŸ”₯1
CHALLENGE

function trickyArgs(a, b, c) {
arguments[0] = 10;
arguments[1] = 20;
arguments[2] = 30;
console.log(a + b + c);
}
trickyArgs(1, 2, 3);
πŸ€”18πŸ‘7❀1
What is the output?
Anonymous Quiz
37%
6
7%
30
54%
60
1%
10
πŸ€”37🀣17πŸ‘11❀3πŸ”₯2