import React from 'react'
import './style.css'

const Button = (props) => {
    
    const buttonStyle = {
      backgroundColor: props.backgroundColor
    }

    return(
      <button id={props.id} style={buttonStyle} onClick={props.onClick}>{props.buttonText}</button>
    )

}

export default Button
import React from 'react'
import './style.css'

function Button(props) {
    
    const buttonStyle = {
      backgroundColor: props.backgroundColor
    }

    return(
      <button id={props.id} style={buttonStyle} onClick={props.onClick}>{props.buttonText}</button>
    )

}

export default Button
Use function declaration not fat arrow
Use function declaration not fat arrow
