T
T
Tema Agaev2019-06-27 02:55:12
Node.js
Tema Agaev, 2019-06-27 02:55:12

How to implement a better delete at a specific time?

Good afternoon. I am writing a todo app. It contains the time at which the task is considered not completed.
The question is how best to track it? On server? On the client? I'm thinking about sockets. But how to track this moment on the server? setInterval doesn't look very good somehow. What other options are there?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Anton Spirin, 2019-06-27
@JustHappyGuest

It is enough to store the expires_at field in the database. And to work with it on the client as it pleases.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question