Skip to main content
AI Assist is now on Stack Overflow. Start a chat to get instant answers from across the network. Sign up to save and share your chats.

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

2
  • It did restrict the user from going past 0 but after that I can't input anything on the input field since it will always set the value to 0 as soon as I type anything. Commented Nov 9, 2022 at 6:05
  • I've added a working example to my answer. If that doesn't help, please update your question with your updated code and we can look at it. Commented Nov 9, 2022 at 14:13