Let’s work on the redux methods. But first, let’s add the required constants to the
SET_LOADING - the value of all constants is equal to their name.
And then add the export of the
getFetchWordEndpoint function to the
This function must take one argument - the word to search for.
It will return the request url, which consists of
These two variables need to add a get parameter
s equal to the function argument
Export three more functions from
Each must return an object with fields
type field is equal to the constants
payload equals the single argument of each function, respectively.
addWord function has
payload all fields of the first argument, padded with the
listKey field, equal to the second argument of the function.
If you have any issues with it, you can ask for community help below the post.
Feel free to help others if you’ve already solved the task.