CHALLENGE
const obj = { a: 1, b: 2, c: 3 };
Object.defineProperty(obj, 'd', {
value: 4,
enumerable: false
});
const entries = Object.entries(obj);
const keys = Object.keys(obj);
const values = Object.values(obj);
console.log(entries.length + keys.length + values.length);β€6π€©1
In many situations, you donβt need a full-on framework to build useful tools; just HTML, JavaScript and CSS in a single file will do the job fine. Simonβs become a bit of an expert by rolling out many such tools using LLMs, and shares his process and practices here. More please!
Simon Willison
Please open Telegram to view this post
VIEW IN TELEGRAM
β€6π2
CHALLENGE
function Vehicle(type) {
this.type = type;
}
Vehicle.prototype.wheels = 4;
Vehicle.prototype.getInfo = function() {
return `${this.type}: ${this.wheels}`;
};
const car = new Vehicle('Car');
const bike = Object.create(car);
bike.type = 'Bike';
bike.wheels = 2;
console.log(car.getInfo() + ' | ' + bike.getInfo());β€7
What is the output?
Anonymous Quiz
53%
Car: 4 | Bike: 2
21%
Car: 4 | Bike: undefined
22%
TypeError: bike.getInfo is not a function
4%
Car: 4 | undefined: 2
The Remix Store is a swag store for the Remix project and its codebase provides a powerful example of how Remixβs own core team builds apps with Remix and Hydrogen.
Brooks Lybrand and the Remix Team
Please open Telegram to view this post
VIEW IN TELEGRAM
β€4π1π₯1