import React from 'react';
import glassDetails from './../../glassDetails.js';
import beerPair from './../../pairList.js';

class Details extends React.Component {
  constructor(props){
  	super(props);
  }

  render(){
  	return(
  	  <div>
        {this.props.updateGlass ? `${glassDetails[this.props.updateGlass]}` : ''}
  	  </div>
  	)
  }
}


export default Details;
import React from 'react';
import glassDetails from './../../glassDetails.js';
import beerPair from './../../pairList.js';

const Details = (props) => {
  return (
    <div>
      {props.updateGlass ? `${glassDetails[props.updateGlass]}` : ''}
    </div>  
  );
}

export default Details;
Refactor details component to stateless component
Refactor details component to stateless component
