Set type of input as "textarea" in styled-components in react


I am making a form similar to Sing UP using react and styled-components. I want to use same <CustomInput type={...} placeholder={...}/> component which I have written but want to achieve input-textarea like functionality is there a way to achieve this.

inside elements.js file

export function CustomInput({ type, placeholder }) {
  return <StyledInput type={type} placeholder={placeholder} />;
}

Source: CSS – Stack Overflow

November 27, 2021
Category : News
Tags: css | html | jsx | reactjs | styled-components

Leave a Reply

Your email address will not be published. Required fields are marked *

Sitemap | Terms | Privacy | Cookies | Advertising

Senior Software Developer

Creator of @LzoMedia I am a backend software developer based in London who likes beautiful code and has an adherence to standards & love's open-source.