Svelte.js deriving stores of stores

Gustav Corpas
5 min readNov 9, 2023

This article is about working with nested stores, or stores of stores, or reactive arrays of stores, or whatever you would want to call them. Basicly this:

const stores = writable([writable(0), writable(0)]);

Why would you want this? Weeell, that part is up to you.. But if you find yourself doing this, stop for a second and consider if you are over-complicating things or if you really need this. Maybe there is an easier way to set up things.

Super quickly about THE BEST FRAMEWORK ❤️

Svelte.js is a javascript framework, that I have fallen completely in love with, and I will allow myself to be super opinionated about it :). It is THE BEST framework, because it is super fast. It’s fast because it is clever about figuring out how reactive values depend on each other at compile time, rather than just updating everything all the time.

Svelte shifts as much work as possible out of the browser and into your build step. No more manual optimisations — just faster, more efficient apps. —

It’s kind off the “keep it simple, stupid” of javascript frameworks.

Super quickly about svelte stores



Gustav Corpas

I write about technology and society. Or anything that is interesting to me.