Home
NOTE: I'm in the middle of upgrading the site. Most things are in place, but some things are missing and/or broken. This includes alt text for images. Please bear with me while I get things fixed.

Dump An Object In React

Use this snippet :

return (
    <div>
        <pre>{JSON.stringify(someObject, null, 2)}</pre>
    </div>
)

To replace this :

return (
    <div>
        {someData}
    </div>
)

When you get errors like :

Unhandled Runtime Error
Error: Objects are not valid as a React child (found: object with keys {displayTitle, primaryKey}). If you meant to render a collection of children, use an array instead.

Call Stack
throwOnInvalidObjectType
~ fin ~