gndx / react-mailchimp-form

React subscribe form for Mailchimp

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Not working with React v18

BearCooder opened this issue · comments

Hi, I try to use react mailchimp form with React 18 but it seems it has a problem with v18

npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: tracker-app@0.1.0
npm ERR! Found: react@18.1.0
npm ERR! node_modules/react
npm ERR! react@"18.1.0" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react@"^16.2.0" from react-mailchimp-form@1.0.2
npm ERR! node_modules/react-mailchimp-form
npm ERR! react-mailchimp-form@"*" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.

Is there any chance that this package gets an update to resolve the conflict? :) @gndx

@BearCooder were you able to resolve this one? I am facing the same issue, but seems like no one is maintaining this npm anymore.

The library is like 1 component that is using 3 libraries (react, jsonp, reactProps).
Just use chatGPT to turn class component into function...
Like this: https://chat.openai.com/share/5196289a-0ff0-41ee-afc6-b2576e43dca7
Works fine for me. The signature (setup) is the same as in readme file.