1.5 KiB
		
	
	
	
	
	
	
	
			
		
		
	
	
			1.5 KiB
		
	
	
	
	
	
	
	
id, title, challengeType, isRequired, forumTopicId
| id | title | challengeType | isRequired | forumTopicId | 
|---|---|---|---|---|
| 5a24c314108439a4d403614e | Define an Action Creator | 6 | false | 301441 | 
Description
Instructions
actionCreator() that returns the action object when called.
Tests
tests:
  - text: The function <code>actionCreator</code> should exist.
    testString: assert(typeof actionCreator === 'function');
  - text: Running the <code>actionCreator</code> function should return the action object.
    testString: assert(typeof action === 'object');
  - text: The returned action should have a key property type with value <code>LOGIN</code>.
    testString: assert(action.type === 'LOGIN');
Challenge Seed
const action = {
  type: 'LOGIN'
}
// Define an action creator here:
Solution
const action = {
  type: 'LOGIN'
}
// Define an action creator here:
const actionCreator = () => {
  return action;
};