To reduce bloat I try to have all my imports use reactn. For example: import React, {useEffect, useState} from 'reactn';
However, with some more esoteric imports I am forced to import from React: import {InputHTMLAttributes} from 'react';
Bumping the @types/react to the latest version may also resolve this issue #98
Also, since I am using the latest React version when I do an NPM install I have to use the --force switch. Here's the NPM Error vomit:
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: [email protected]
npm ERR! Found: @types/[email protected]
npm ERR! node_modules/@types/react
npm ERR! @types/react@"^17.0.37" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer @types/react@"^16.8.0" from [email protected]
npm ERR! node_modules/reactn
npm ERR! reactn@"^2.2.7" from the root project