skip to Main Content

Javascript – Displaying Inputbox only when we "Yes" option is selected from dropdown

import React, { useState } from "react"; function FormHooks(props){ const [showtext,setShowText]=useState("") const handleChange = (e)=>{ const getvalue = e.target.value console.log(getvalue) setShowText(getvalue) } return( <div> {showtext?<input type="text" placeholder="Enter Company name"/>:null} <form> <div> <label>Are you employed?</label> <select onChange={handleChange}> <option value="select">select</option> <option value="Yes">Yes</option>…

VIEW QUESTION

React Native const value changing

In my React-Native App; I have one const variable declared as below in one component named: constants.js export const IS_VIA_DEEP_LINK = false Now, In my Splashscreen.js I am doing as below: constants.IS_VIA_DEEP_LINK=true; When I try to access the value of…

VIEW QUESTION
Back To Top
Search