Algebraic Effects for the Rest of Us
– overreacted.io – Edit
You can think of algebraic effects as resumeable try catch blocks ?. In a new post on his blog React dev Dan Abramov explains the concept.
Read more [overreacted.io]
Posts tagged with javascript
– overreacted.io – Edit
You can think of algebraic effects as resumeable try catch blocks ?. In a new post on his blog React dev Dan Abramov explains the concept.
Read more [overreacted.io]
Nicolas Beauvais wrote a nice blogpost on how he went about adding support for internationalization to his app.
When working on web applications, translation strings are typically stored in the backend of your app while they’re mostly used in the frontend. This is the main challenge because you need to communicate the translations from your backend to your frontend code.
Read more [nicolas-beauvais.com]
Join 9,500+ smart developers
Get my monthly newsletter with what I learn from running Spatie, building Oh Dear, and maintaining 300+ open source packages. Practical takes on Laravel, PHP, and AI that you can actually use.
No spam. Unsubscribe anytime. You can also follow me on X.
"Freek’s newsletter is one of the best ways to stay updated with the Laravel and PHP ecosystem. It consistently highlights useful packages, tools, and ideas from the community, especially the amazing work coming from Spatie. As a Laravel developer building SaaS and web platforms, I find it extremely helpful to discover practical tools and insights that improve my development workflow."
– twitter.com – Edit
? Perf tip: if your web app ships large JSON-like configuration as JavaScript object literals, consider using JSON.parse instead. It’s much faster, especially for cold loads! https://t.co/C0oQ4BLnfz pic.twitter.com/p0WICUm7zx
— Mathias Bynens (@mathias) June 25, 2019
Read more [twitter.com]
In a new blogpost, my colleague Seb explains why you should and how you can use useEffect.
React recently introduced a new way to deal with side effects: the
useEffecthook. Translating lifecycle methods touseEffectcalls can be confusing at first. It’s confusing because we shouldn’t be translating imperative lifecycle methods to declarative useEffect calls in the first place.
Read more [sebastiandedeyne.com]
– twitter.com – Edit
If you're debugging an array or an object, try console.table() instead of console.log()! It gives you a muuuuch better visual representation of the data in the console ? pic.twitter.com/5V9TCsBiOK
— Erin ? (@erinfranmc) June 10, 2019
Read more [twitter.com]
In a new blogpost, Sebastian De Deyne compares Vue syntax with React syntax.
This post is a succinct rundown of most Vue features, and how I would write them with React in 2019 with hooks.
Read more [sebastiandedeyne.com]
– www.netlify.com – Edit
Hooks is feature was added recently to React that I really like.
In this article, we reintroduce closures by building a tiny clone of React Hooks. This will serve two purposes – to demonstrate the effective use of closures, and to show how you can build a Hooks clone in just 29 lines of readable JS. Finally, we arrive at how Custom Hooks naturally arise.
Read more [www.netlify.com]
In the latest episode of Full Stack Radio podcast, my colleague Seb explains the differences between React and Vue.
In this episode, Adam talks to Sebastian De Deyne about learning React from the perspective of a Vue developer, and how to translate all of the Vue features you're already comfortable with to React code.
Read more [www.fullstackradio.com]
– rawgit.com – Edit
Here's a PDF, made by Ryan Grove, that executes JavaScript when you open it in Chrome.
Read more [rawgit.com]
My colleague Seb gives some good reasons why he personally likes working with React over Vue.
Vue is the default JavaScript framework for Laravel apps. Being part of the Laravel community, I often get the question why I prefer React, so I've decided to write down a few standout reasons.
Read more [sebastiandedeyne.com]
– madewithlove.be – Edit
In a new post at the madewithlove blog, Geoffrey Dhuyvetters explains how you can organize your code so a bundler can make it as small as possible.
As an author of (open source) packages, I think you have the responsibility to protect the bundle size of your package consumer. When you publish a package that exports a whole range of modules (for example lodash, ramda, date-fns…) you want to make sure the package is exported in such a way that the consumer of your package (mostly bundlers) can optimize size.
Read more [madewithlove.be]
Sebastian wrote a short post on how to configure Husky to run Prettier on every commit.
I'm a happy prettier user to keep my CSS and JavaScript files consistent. However, it's hard to keep the discipline to run Prettier before every commit. This week I decided to automate the process with Husky and lint-staged.
Read more [sebastiandedeyne.com]
– kentcdodds.com – Edit
Kent C. Dodds guides us through creating our first function on Netlify.
Luckily for us, almost exactly one year ago from the time I'm writing this, Netlify took the complexity of AWS Lambda functions and made it super simple.
Read more [kentcdodds.com]
– reinink.ca – Edit
Jonathan Reinink is creating a library that'll make it easy to create server-driven single-page apps. Super cool idea!
I wanted to blend the best parts of classic server-side apps (routing, controllers, and ORM database access) with the best parts of single-page apps (JavaScript rendering and no full page reloads). Or, at least the best parts as I see them. ?
That journey has led me to a pretty interesting new pattern, which this article explains in detail. In short, I've created a Turbolinks inspired library that makes it super easy to create server-driven single-page apps. I am calling this library Inertia.js.
Read more [reinink.ca]
– overreacted.io – Edit
In an impressive blog post on his blog, React lead developer Dan Abramov, explains how React works on the hood.
This is a deep dive — THIS IS NOT a beginner-friendly post. In this post, I’m describing most of the React programming model from first principles. I don’t explain how to use it — just how it works. It’s aimed at experienced programmers and folks working on other UI libraries who asked about some tradeoffs chosen in React. I hope you’ll find it useful!
Read more [overreacted.io]
– overreacted.io – Edit
React lead Dan Abramov breaks down the statement "function components capture the rendered values". To me hooks seem like a very cool feature that'll make your react components much more easier to write.
Read more [overreacted.io]
– Edit
Here's a presentation from the Netflix engineering team on how they made the interface for Netflix' interactive movie Bandersnatch.
– reinink.ca – Edit
Jonathan Reinink proposes a new take on what Vue's role could be in a server rendered app.
What I have here is a classic server-side app, that uses server-side routing and controllers. There is no API. The controllers lookup the data from the database, and then pass it to the templates. Except, I'm not using any server-side (ie. Blade) templates. Instead I'm doing full client-side rendering using Vue.js. Confused yet? Let me explain.
Read more [reinink.ca]
– 2ality.com – Edit
JavaScript has two zeros: −0 and +0. This post explains why that is and where it matters in practice.
Read more [2ality.com]