ryder.dev

Grommet DataTable ReferenceError defaultProps

April 06, 2021

Error

ReferenceError: defaultProps is not defined

Solution

Did you forget to import React?

Add import React from 'react' to the top of your file.

Prevent this error in the future

Consider using Typescript for future projects, as it will help you sort out these and many other similar issues.