Warning: Failed prop type: The prop `createCourse` is marked as required in `CoursesPage`, but its value is `undefined`

Bob Sanders

My code works without mapDispatchToProps function and setting the dispatch function at the handleSubmit and at CoursesPage.propTypes instead of using createCourse. I've updated the CoursesPage.js code in order to use mapDispatchToProps and something has broke. This is my code at sandbox

devdev_dev

You have two problems:

  1. You need to pass mapDispatchToProps to connect
export default connect(mapStateToProps, mapDispatchToProps)(CoursesPage);
  1. createCourse is not a prop, it's a function you're importing

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

Failed prop type The prop is marked as required but its value is `undefined`

How to fix this issue “Warning: Failed prop type: The prop `title` is marked as required in `Tab`, but its value is `undefined`.”

Warning: Failed prop type: The prop `store` is marked as required in `Provider`, but its value is `undefined`. in Provider

Warning: Failed prop type: The prop open is marked as required in Snackbar, but its value is undefined

Warning: Failed prop type: The prop `todos[0].title` is marked as required in `TodoList`, but its value is `undefined`

Warning: Failed prop type: The prop `alt` is marked as required in `MainImage`, but its value is `undefined`. MainImage

reactjs Delete Operation Warning: Failed prop type: The prop `role` is marked as required in `ManageRolePage`, but its value is `null`

Failed prop type: The prop `children` is marked as required in `InputAdornment`, but its value is `undefined`

Failed prop type: The prop `options` is marked as required in `signupCheckBoxes`, but its value is `undefined`

Failed prop type: The prop `children` is marked as required in` Sidebar`, but its value is `undefined`

Failed prop type: The prop todos[0].id is marked as required in TodoList, but its value is undefined

Failed prop type: The prop `userSignUpRequest` is marked as required in `Login`, but its value is `undefined`

Failed prop type: The prop `children` is marked as required in `Mutation`, but its value is `undefined`

Failed prop type: The prop `auth` is marked as required in `Navbar`, but its value is `undefined`

React - Failed prop type: The prop `history` is marked as required in `Router`, but its value is `undefined`

Prop is marked as required in component, but its value is `undefined`

Failed prop type: The prop `children` is marked as required in `e`, but its value is `null`

The prop `history` is marked as required in `Router`, but its value is `undefined`. in Router

The prop `classes` is marked as required in `FullWidthGrid`, but its value is `undefined`

The prop `children` is marked as required in `Button`, but its value is `undefined`

The prop `checked` is marked as required in `ToggleSwitch`, but its value is `undefined`

React Native: Failed prop type: the prop businessPhoneNumberChanged is marked as required

React-Native this prop randomNumberCount is marked as required in Game ,but its value undefined

React-redux error "The prop `store` is marked as required in `Root`, but its value is `undefined"

ReactJS Failed Prop Type With 'undefined' Value

React : Warning: Failed prop type: Cannot read property 'apply' of undefined

Failed prop type: Invalid prop 'value'

Failed prop type. Required prop types are undefined in my redux store

Warning: Failed prop type: Invalid prop `value` of type `number` supplied to `TextInput`, expected `string`

TOP Ranking

  1. 1

    Failed to listen on localhost:8000 (reason: Cannot assign requested address)

  2. 2

    pump.io port in URL

  3. 3

    How to import an asset in swift using Bundle.main.path() in a react-native native module

  4. 4

    Loopback Error: connect ECONNREFUSED 127.0.0.1:3306 (MAMP)

  5. 5

    Compiler error CS0246 (type or namespace not found) on using Ninject in ASP.NET vNext

  6. 6

    BigQuery - concatenate ignoring NULL

  7. 7

    Spring Boot JPA PostgreSQL Web App - Internal Authentication Error

  8. 8

    ggplotly no applicable method for 'plotly_build' applied to an object of class "NULL" if statements

  9. 9

    ngClass error (Can't bind ngClass since it isn't a known property of div) in Angular 11.0.3

  10. 10

    How to remove the extra space from right in a webview?

  11. 11

    Change dd-mm-yyyy date format of dataframe date column to yyyy-mm-dd

  12. 12

    Jquery different data trapped from direct mousedown event and simulation via $(this).trigger('mousedown');

  13. 13

    maven-jaxb2-plugin cannot generate classes due to two declarations cause a collision in ObjectFactory class

  14. 14

    java.lang.NullPointerException: Cannot read the array length because "<local3>" is null

  15. 15

    How to use merge windows unallocated space into Ubuntu using GParted?

  16. 16

    flutter: dropdown item programmatically unselect problem

  17. 17

    Pandas - check if dataframe has negative value in any column

  18. 18

    Nuget add packages gives access denied errors

  19. 19

    Can't pre-populate phone number and message body in SMS link on iPhones when SMS app is not running in the background

  20. 20

    Generate random UUIDv4 with Elm

  21. 21

    Client secret not provided in request error with Keycloak

HotTag

Archive