import React from 'react';
import { bindActionCreators } from 'redux';
import { connect } from 'react-redux';
import { addSong } from '../actions/add_song_action.js';
class AddSong extends React.Component {
	render() {
		return (
			<div>
				<form onSubmit={(e) => {
					e.preventDefault()
					this.props.addSong({title: "saaahdude", artist:"dillon", genre:"rap"})
				}}>
					<input></input>
					<button type="submit">Add</button>
				</form>
			</div>
		)
	}
};

function mapStateToProps(state) {
	return { 
		songs : state.songs 
	}; 
};

function matchDispatchToProps(dispatch) {
	return bindActionCreators({ addSong: addSong }, dispatch)
}

export default connect(mapStateToProps, matchDispatchToProps)(AddSong);
@@ -160,16 +160,18 @@
 on.js';%0A
+%0A%0A
 class Ad
@@ -234,16 +234,49 @@
 %09%09%3Cdiv%3E%0A
+%09%09%09%09%3Ch2%3E%7B this.props.name %7D%3C/h2%3E%0A
 %09%09%09%09%3Cfor
@@ -494,20 +494,151 @@
 %0A%09%09)%0A%09%7D%0A
-
 %7D;%0A%0A
+AddSong.propTypes = %7B%0A%09name: React.PropTypes.string,%0A%09addSong: React.PropTypes.func%0A%7D%0A%0AAddSong.defaultProps = %7B%0A%09name: 'Dillon'%0A%7D%0A%0A
 function

add some proptypes and default props for practice