Integration problem in nextjs.
AdrianEasyOze opened this issue · 0 comments
AdrianEasyOze commented
implementation
import { Waypoint } from "react-waypoint";
export const PhotovilatisPro: React.FC = () => {
const { popup } = usePopup();
return (
<>
<PhotovilatisProWrapper>
<StickyBar>
FOTOWOLTAIKA
</StickyBar>
{popup === "createLeadProPV" && <CreateLeadProPV />}
<Waypoint>
<TechnicalData />
<Parameters />
<GradientLine />
<Map />
<ImageUploader />
<Summary />
</Waypoint>
</ProWrapper>
</>
);
};
Error
Error: Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: undefined. You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.
console error
The above error occurred in the <Waypoint> component:
Waypoint@webpack-internal:///./node_modules/react-waypoint/es/index.js:235:34
div
withEmotionCache/<@webpack-internal:///./node_modules/@emotion/react/dist/emotion-element-6a883da9.browser.esm.js:57:66
PhotovilatisPro@webpack-internal:///./src/components/organisms/calculators/SolarCalculator/pages/PhotovilatisPro/index.tsx:30:75
div
withEmotionCache/<@webpack-internal:///./node_modules/@emotion/react/dist/emotion-element-6a883da9.browser.esm.js:57:66
BaseLayout@webpack-internal:///./src/layouts/BaseLayout/index.tsx:19:18
PhotovoltaicsProPage
Notyfication@webpack-internal:///./src/components/atoms/Notyfication/index.tsx:22:18
ThemeProvider@webpack-internal:///./node_modules/@emotion/react/dist/emotion-element-6a883da9.browser.esm.js:96:64
Provider@webpack-internal:///./node_modules/unstated-next/dist/unstated-next.mjs:13:17
Provider@webpack-internal:///./node_modules/unstated-next/dist/unstated-next.mjs:13:17
Provider@webpack-internal:///./node_modules/unstated-next/dist/unstated-next.mjs:13:17
Provider@webpack-internal:///./node_modules/unstated-next/dist/unstated-next.mjs:13:17
Provider@webpack-internal:///./node_modules/unstated-next/dist/unstated-next.mjs:13:17
Provider@webpack-internal:///./node_modules/unstated-next/dist/unstated-next.mjs:13:17
ProviderGroup@webpack-internal:///./src/container/providers.tsx:22:18
QueryClientProvider@webpack-internal:///./node_modules/react-query/es/react/QueryClientProvider.js:39:16
App@webpack-internal:///./src/pages/_app.tsx:52:19
PathnameContextProviderAdapter@webpack-internal:///./node_modules/next/dist/shared/lib/router/adapters.js:101:18
ErrorBoundary@webpack-internal:///./node_modules/next/dist/compiled/@next/react-dev-overlay/dist/client.js:2:3209
ReactDevOverlay@webpack-internal:///./node_modules/next/dist/compiled/@next/react-dev-overlay/dist/client.js:2:6087
Container@webpack-internal:///./node_modules/next/dist/client/index.js:118:20
AppContainer@webpack-internal:///./node_modules/next/dist/client/index.js:303:18
Root@webpack-internal:///./node_modules/next/dist/client/index.js:519:19
React will try to recreate this component tree from scratch using the error boundary you provided, ErrorBoundary```