/react-field-example

React ( Using Functional Component )

Primary LanguageJavaScript

React ( Using Functional Component )

  1. create a field "Number".

User will enter a number between 1-12 (React)

for example, I enter 5 my result will

Month Value Copy

Jan [input for enter value] [copy button]

Feb [input for enter value] [copy button]

Mar [input for enter value] [copy button]

Apr [input for enter value] [copy button]

May [input for enter value] [copy button]

Here logic is,

when I enter any value, copy button should enable, otherwise all button will be disabled by default.

when I click on copy it should copy same values in next all months, not previous one.

so if I enter value 50 in Feb then Mar, Apr, May will have value 50.