client/src/components/Note.js
author Alexandre Segura <mex.zktk@gmail.com>
Wed, 31 May 2017 17:51:54 +0200
changeset 12 48ddaa42b810
parent 1 431977d7c9a6
child 15 4a8bbd314a46
permissions -rw-r--r--
Draft implementation of sessions. - Introduce react-router & add some pages. - Add login page (does nothing). - Allow creating a new session. - Allow adding notes into a session.

import React from 'react';
import PropTypes from 'prop-types';

const Note = ({note}) => {
  return (
    <div id={"note-" + note.id}>
      {note.text}
    </div>
  );
};

Note.propTypes = {
  note: PropTypes.object.isRequired
};

export default Note;