I'm getting started with React and I'm wondering why they choose to use this notation:
const counter = (state, action) => {} 
instead of the old-traditional:
function counter(state, action){}
I'm wondering if that's because of the const keyword. Because it is not possible to create a const function as it (as stated there: Are there constants in JavaScript?)
is that the only reason? I understand that const functions are important in React, to ensure the behavior isn't changed at runtime. But I wonder if that's the only reasons why they choose to use it.
 
     
    