You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
i don't think this is standard in cjs projects to compile anything in node_modules, it generally accepted that modules should work without additional developer steps
Error:
import React, { useState, useEffect } from "react";
^^^^^^
SyntaxError: Cannot use import statement outside a module
at wrapSafe (internal/modules/cjs/loader.js:1167:16)
at Module._compile (internal/modules/cjs/loader.js:1215:27)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1272:10)
at Module.load (internal/modules/cjs/loader.js:1100:32)
at Function.Module._load (internal/modules/cjs/loader.js:962:14)
at Module.require (internal/modules/cjs/loader.js:1140:19)
at require (internal/modules/cjs/helpers.js:75:18)
at eval (webpack-internal:///recoilize:1:18)
at Object.recoilize ([REDACTED]/.next/server/pages/_app.js:441:1)
at __webpack_require__ ([REDACTED]/.next/server/pages/_app.js:23:31)
I'd be happy to open a PR fixing the build to make it usable in common js projects, or maybe so it can be used by both mjs and cjs?
The text was updated successfully, but these errors were encountered:
Reproduction Steps
Error:
I'd be happy to open a PR fixing the build to make it usable in common js projects, or maybe so it can be used by both mjs and cjs?
The text was updated successfully, but these errors were encountered: