Skip to content

WIP: initial form component commit - #2

Open
alexander2402 wants to merge 5 commits into
masterfrom
formDev
Open

WIP: initial form component commit#2
alexander2402 wants to merge 5 commits into
masterfrom
formDev

Conversation

@alexander2402

Copy link
Copy Markdown
Collaborator

created few directories:

  1. src/components
  2. src/components/form

added empty component "form"

@Kronenberg Kronenberg added the wontfix This will not be worked on label Dec 30, 2018
@Kronenberg Kronenberg changed the title initial form component commit WIP: initial form component commit Dec 30, 2018
Comment thread .idea/workspace.xml Outdated
<window_info anchor="bottom" id="Find" order="1" />
<window_info anchor="bottom" id="Run" order="2" />
<window_info anchor="bottom" id="Debug" order="3" weight="0.4" />
<window_info anchor="bottom" id="Cvs" order="4" weight="0.25" />

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

git ignore for this files

Comment thread src/App.js
import logo from './logo.svg';
import './App.css';
import Form from './components/form/'
import 'bootstrap/dist/css/bootstrap.css';

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't use bootstrap please !
only display:flex

Comment thread src/App.js
_onChangeInputConPass = (e) => {
const {value} = e.target;
this.setState({inputConPass: value});
};

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

all your actions do same job, am i right?
create one action for all the fields
this article might help you: https://reactjs.org/docs/forms.html

Comment thread src/App.js
return (
<div className="App">
<Form
inputName={this.state.inputName}

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i dont need action for every input field, as i told before it should we one method

} = this.props;

return (
<div className='container formmasa'>

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

formmasa? proper name please

Comment thread src/App.js
// console.log(this.state);
return (
<div className="App">
<Form

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

make this form reusable, provide few examples how i can use your form component for login and logout page's

render() {
const {
inputName, inputSurName, inputEmail, inputPass, inputConPass, change1, change2, change3,
change4, change5, formValid

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

change 4 change 5? 👎 proper names

<input className="form-control mt-3 mb-4 ml-2 col-5"
placeholder="Surname"
value={inputSurName}
onChange={change2}/>

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

change2?

<input className="form-control mt-3 mb-4 ml-4 col-5"
placeholder="Name"
value={inputName}
onChange={change1}/>

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

change1?

</div>
</div>
</div>
<div className='col-6 mt-5'>

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mt-5?

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

did i show this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

wontfix This will not be worked on

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants