SolidJSS
SolidJS3y ago
5 replies
vveisard

How to create effect for each element of mapArray?

Hello,

I'm exploring reactive patterns, and I'm stumped on how to create effects for elements of the result of mapArray.

What I've got so far:
https://github.com/vveisard/fiddle-solid-array-effect/blob/main/src/index.ts

I'm thinking the return type of those memos ought to be Accessor<Array<Accessor<Array>>>, right? But how do I create that structure, and how to I create an effect that runs when the array element changes?
GitHub
Contribute to vveisard/fiddle-solid-array-effect development by creating an account on GitHub.
fiddle-solid-array-effect/src/index.ts at main · vveisard/fiddle-so...
Was this page helpful?