Redux: actionCreater Section

Tell us what’s happening:
Hello, could somebody explain me what is wrong in this snippet? Everything seems correct: the function is working, so it returns the value that I defined before but I take this error message : " A function named actionCreater() should exist"

  **Your code so far**

const action = {
type: 'LOGIN'
}
// Define an action creator here:

function actionCreater() {
return action;
}

console.log(actionCreater())

console.log(actionCreater().type)

  **Your browser information:**

User Agent is: Mozilla/5.0 (Linux; Android 11; M2012K10C) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/98.0.4758.87 Mobile Safari/537.36

Challenge: Define an Action Creator

Link to the challenge:

There is a speling error in your function name.

1 Like

Oh thank you, it works now.

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.