Menu

A notice to every account goes out 100 at a time, and the browser is what keeps the loop going
📰

A notice to every account goes out 100 at a time, and the browser is what keeps the loop going

DEV Community: nextjs·Daniel Pertu·14 days ago
#FSybeF07
#devtonextjs#devto#dev#unsubscribe#token
Reading 0:00
15s threshold

Sometimes Nakodo has to tell every account holder

something: the terms changed, there was an outage, a plan is being renamed.

That is one of those features that looks like an afternoon and turns out to be

mostly about what must not happen.

The shape it ended up with: a Server Action that sends one batch of at most

100 and then stops, and a browser that calls it again with the cursor it was

handed. The server never loops.

Four modes, and keeping them apart is the point

test One copy to the operator's own address, so the real email can be read in a real inbox before anyone else gets it. direct One email to a named address. For writing to one person who may not have an account, so it carries no "you have an account" footer. accounts Service email to every account holder. Not consent-gated and carries no unsubscribe link: there is nothing to leave short of closing the account. marketing Product news, to the people who opted in.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.