Skip to content

Instantly share code, notes, and snippets.

@rocifier
Created December 9, 2018 02:37
Show Gist options
  • Save rocifier/d4c8820ce146e9531e12f2281466f984 to your computer and use it in GitHub Desktop.
Save rocifier/d4c8820ce146e9531e12f2281466f984 to your computer and use it in GitHub Desktop.
import React, { Component } from 'react';
const TeacherIntroductions = ({ teachers }) => (
<ul className="teacher-introductions">
{teachers.map((teacher, index) => {
return <TeacherIntroduction key={`teacher-${teacher.id}`} teacher={teacher} />;
})}
</ul>
)
const mapStateToProps = state => {
return state.teachers
}
export default connect(mapStateToProps)(TeacherIntroductions)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment