Skip to content

Trying to use and edit src/example/github-example.js #74

@cimerejb

Description

@cimerejb

I first create a default react project using npx create-react-app
then
I install the object-editor-react via npm
then
I copy the src directory (by downloading it from git), overwriting my src directory

WHen I try to run npm start, I get:

Failed to compile

src/util.js
Line 54:25: React Hook "R.useWith" cannot be called at the top level. React Hooks must be called in a React function component or a custom React Hook function react-hooks/rules-of-hooks

Search for the keywords to learn more about each error.
"

It appears that the utils.js has a fundamental issue that violates this 'React Hook' principle.
Since I am not an expert, I don't know yet how to go around this issue.

Any idea what I am doing wrong?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions