JavaScript
32K subscribers
1.04K photos
10 videos
33 files
717 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
SPONSORED BY Lantern Cloud 👯‍♀️
Vector database on top of Postgres for AI

CHALLENGE

const a = { value: 1 };
const b = Object.create(a);
b.value = 2;

console.log(b.value);
console.log(a.value);
Please open Telegram to view this post
VIEW IN TELEGRAM
👍3
What is the output?
Anonymous Quiz
55%
2, 1
23%
2, 2
16%
1, 2
6%
1, 1
🤔136🤣5👍4🔥3🤩1
Please open Telegram to view this post
VIEW IN TELEGRAM
👍6🤣43🔥1
SPONSORED BY Lantern Cloud 👯‍♀️
Vector database on top of Postgres for AI

CHALLENGE
let count = 0;

const counter = (function() {
count = 0;
return function() {
count += 1;
return count;
};
})();

count = 10;
counter();
console.log(count);
Please open Telegram to view this post
VIEW IN TELEGRAM
🤩6👍3🔥21🤔1
What is the output?
Anonymous Quiz
13%
0
50%
11
29%
1
8%
NaN
👍9🤩63
SPONSORED BY Lantern Cloud 👯‍♀️
Vector database on top of Postgres for AI

🥹😂😆emoji-picker-element: A Lightweight Emoji Picker

An emoji picking control, packaged as a Web Component. You can also add custom emoji to it. GitHub repo.

Nolan Lawson
Please open Telegram to view this post
VIEW IN TELEGRAM
3🔥3👍2
SPONSORED BY Lantern Cloud 👯‍♀️
Vector database on top of Postgres for AI

CHALLENGE
const target = {
age: 30
};

const handler = {
get: function(obj, prop) {
return obj[prop]++;
}
};

const proxy = new Proxy(target, handler);

console.log(proxy.age);
console.log(target.age);
console.log(proxy.age);
Please open Telegram to view this post
VIEW IN TELEGRAM
👍8🤔7🔥43
🤔8👍75
SPONSORED BY Lantern Cloud 👯‍♀️
Vector database on top of Postgres for AI

🥶 A Different Way to Think About TypeScript

“a very expressive way to operate over sets, and using those sets to enforce strict compile time checks”

Robby Pruzan
Please open Telegram to view this post
VIEW IN TELEGRAM
👍53🔥3
SPONSORED BY Lantern Cloud 👯‍♀️
Vector database on top of Postgres for AI

CHALLENGE

let obj1 = { key: 'value1' };
let obj2 = { key: 'value2' };

const weakMap = new WeakMap();
weakMap.set(obj1, 'data1');
weakMap.set(obj2, 'data2');

obj1 = null;
setTimeout(() => {
console.log(weakMap.has(obj1));
console.log(weakMap.has(obj2));
}, 100);
Please open Telegram to view this post
VIEW IN TELEGRAM
5👍2🤔2🤩1
🔥11👍7🤔63
SPONSORED BY Lantern Cloud 👯‍♀️
Vector database on top of Postgres for AI

😆 My code after the refactoring
Please open Telegram to view this post
VIEW IN TELEGRAM
🤣173👍3
SPONSORED BY Lantern Cloud 👯‍♀️
Vector database on top of Postgres for AI

CHALLENGE
const target = {
secret: "hidden",
reveal: "nothing"
};

const handler = {
get: function(obj, prop, receiver) {
if (prop === "secret") {
return "revealed";
}
return Reflect.get(...arguments);
}
};

const proxy = new Proxy(target, handler);

with (proxy) {
console.log(secret);
console.log(reveal);
}
Please open Telegram to view this post
VIEW IN TELEGRAM
2
🔥8🤔5👍42
SPONSORED BY Lantern Cloud 👯‍♀️
Vector database on top of Postgres for AI

😆 ✌️ vs 🥶
Please open Telegram to view this post
VIEW IN TELEGRAM
🤣46👍96🤔2🤩1
CHALLENGE

function* evenNumbers() {
let num = 0;
while (true) {
yield num;
num += 2;
}
}

const gen = evenNumbers();
const evens = Array.from({ length: 4 }, () => gen.next().value).map(n => n + 1);

console.log(evens);
👍2
🤣12👍8🤩5🔥3
SPONSORED BY Lantern Cloud 👯‍♀️
Vector database on top of Postgres for AI

This is a treasure!

✌️ Do you have any (old or new) Javascript book laying around? We want to see some pictures.

Share with us
Please open Telegram to view this post
VIEW IN TELEGRAM
👍134🔥2
SPONSORED BY Lantern Cloud 👯‍♀️
Vector database on top of Postgres for AI

CHALLENGE

function* numberDoubler(arr) {
for (const num of arr) {
yield num * 2;
}
}

const result = [...numberDoubler([1, 2, 3])].some(n => n % 4 === 0);

console.log(result);
Please open Telegram to view this post
VIEW IN TELEGRAM
What is the output?
Anonymous Quiz
23%
undefined
24%
false
16%
Error
37%
true
👍11🤔5🔥31
This media is not supported in your browser
VIEW IN TELEGRAM
SPONSORED BY Lantern Cloud 👯‍♀️
Vector database on top of Postgres for AI

🆒 Projects on roadmap.sh

Projects are a fantastic way to validate your learning and solidify your knowledge. We're thrilled to introduce projects across all of our 50+ roadmaps!

We're starting with the backend roadmap, which now features 18 project ideas of varying difficulty levels. We'll gradually add projects to all our roadmaps making our roadmaps even more powerful.

Kamran Ahmed
Please open Telegram to view this post
VIEW IN TELEGRAM
10👍2🤩1