score:0

the code is passing a javascript object to the combinereducers() function. there are 2 ways to add elements to the object:

{item: item}

and

{item}

while the latter is a shorthand for the first one. the shorthand only works if object key and variable name are the same.

the code could have also been written like this:

{
  article: article,
  articlelist: articlelist,
  auth: auth,
  router: routerreducer
}

score:2

actually, it should be the clearest line because you're defining an object, a key and value pairs collection. in fact, your code is equivalent to:

export default combinereducers({
  article: article,
  articlelist: articlelist,
  auth: auth,
  router: routerreducer
});

thanks to an es6 feature


Related Query

More Query from same tag