Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- const inputType = (type) => {
- console.log('type: ' + type)
- switch(type) {
- case 'textarea':
- <Textarea
- id={id}
- placeholder={placeholder}
- value={value}
- error={error}
- />
- break;
- case 'input':
- <Input
- id={id}
- type={type}
- placeholder={placeholder}
- value={value}
- error={error}
- />
- break;
- }
- }
Add Comment
Please, Sign In to add comment