79496739

Date: 2025-03-09 23:07:11
Score: 1
Natty:
Report link

The tutorial only includes a button for incrementing the counter so using the mod function would work in the context of this component tutorial.

If the component your designing allows the parent component to set a value directly (as opposed to just incrementing) then you'd probably want to set the private _counter back to the starting number (and ensure that it also properly notifies the parent component that the value was modified).

Reasons:
  • No code block (0.5):
  • Low reputation (0.5):
Posted by: Unlearnd