JavaScript
32K subscribers
1.02K photos
9 videos
33 files
705 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
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ‘7❀3πŸ”₯2
CHALLENGE ❓


const obj = {};
Object.defineProperty(obj, 'name', {
value: 'Alice',
writable: false,
configurable: false
});

try {
obj.name = 'Bob';
delete obj.name;
console.log(obj.name);
} catch (e) {
console.log('Error:', e.message);
}
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ”₯3πŸ‘1
🀟 Node v20.18.0 (LTS) Released; v20 'Iron' Prepares to Bow Out as Active LTS Release

It’s been a quiet few weeks for official releases. This update marks one of the last in Node 20’s run as the active LTS release, and introduces experimental network inspection support. Node 22 will soon take over the active LTS crown (as per schedule) but what will its codename be given there are no elements starting with J? Amazingly, this question was asked six years ago and it's (probably) going to be Jod.

MichaΓ«l Zasso
Please open Telegram to view this post
VIEW IN TELEGRAM
❀6πŸ‘4πŸ”₯2
CHALLENGE ❓


const map = new Map();
const key1 = {};
const key2 = key1;

map.set(key1, "Value for key1");
map.set(key2, "Value for key2");

console.log(map.get({}));
console.log(map.get(key1));
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ‘3❀1
πŸ”₯8❀4πŸ‘4🀣4
πŸ‘€ The Story of Web Framework Hono, By Its Creator

Hono is a neat, lightweight framework designed to run on any JavaScript runtime that has been picking up steam in the past year. You can create a simple app reminiscent of Express.js, say, but run it on Cloudflare Workers, Deno, Bun, or Node. It’s in heavy use all over the place, and has lots of interesting features like letting you write HTML with JSX.

Yusuke Wada
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ‘4❀1πŸ”₯1
πŸ₯‚ We Did It – 25K Subscribers!

We're excited to announce that our newsletter reached 25,000 subscribers! This was one of our biggest goals for 2024, and we couldn’t have done it without your amazing support.

Thank you for being part of this journey. We’ve got more exciting content coming, so stay tuned!
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ”₯29πŸ‘8❀6🀩3
CHALLENGE ❓


Promise.resolve(1)
.then(value => {
console.log(value);
throw new Error('Something went wrong');
})
.then(() => {
console.log('This will not run');
})
.catch(error => {
console.log('Caught:', error.message);
return 42;
})
.then(value => {
console.log('Recovered with:', value);
});
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ‘3πŸ€”2
πŸ˜† True ...

It's just easy to start.
Please open Telegram to view this post
VIEW IN TELEGRAM
🀣64πŸ‘9❀4πŸ€”1🀩1
CHALLENGE ❓


const sym = Symbol('unique');
const obj = {
[sym]: 'Secret',
public: 'Visible'
};

console.log(Object.keys(obj));
console.log(obj[Symbol('unique')]);
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ‘2
🀟 To ensure your Node.js version is secure, use:


npx is-my-node-vulnerable


A tool created and maintained by the Node.js security team. This utility allows you to quickly check for known vulnerabilities and helps safeguard your projects.
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ‘13❀6πŸ”₯6🀩2
CHALLENGE

for (var i = 0; i < 3; i++) {
setTimeout(() => console.log(i), 100);
}
❀4πŸ‘3
πŸ€”25πŸ‘14🀩6πŸ”₯5🀣2
Please open Telegram to view this post
VIEW IN TELEGRAM
πŸ‘7πŸ”₯2❀1
CHALLENGE

function Person(name) {
this.name = name;
}

Person.prototype.greet = function () {
console.log(`Hello, ${this.name}`);
};

const person = new Person('Alice');
person.greet();

console.log(person.hasOwnProperty('greet'));
πŸ‘7
πŸ‘18πŸ€”8πŸ”₯2
🀟 Node v23.0.0 (Current) Released

Say hello to the newest release line of Node.js that gets all the cutting edge features first (Node 22 will soon become the active LTS release). v23 notably enables support for loading ES modules with require() by default, drops 32-bit Windows support, and node --run goes stable.

Rafael Gonzaga
Please open Telegram to view this post
VIEW IN TELEGRAM
❀10πŸ‘4πŸ”₯3
CHALLENGE

console.log(typeof NaN);
console.log(NaN === NaN);
🀣21πŸ€”5❀2