mischnic / proton-hot-cli

Hot-reloading babel-node for proton-native apps
MIT License
0 stars 0 forks source link

Improve error messages #3

Open mischnic opened 6 years ago

mischnic commented 6 years ago

Is that even possible?

$ yarn start
yarn run v1.9.4
$ cd example && cross-env TEST_CLI=true ../cli.js src/index.js
[HMR] Waiting webpack...
[HMR] Launch assets in forked process.
[HMR] Waiting for update signal from webpack...
Warning: React.createElement: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: undefine
d. You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.

Check the render method of `Wrapper`.
    in Wrapper
Warning: React.createElement: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: undefine
d. You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.

Check the render method of `Wrapper`.
    in Wrapper
The above error occurred in the <Wrapper> component:
    in Wrapper

Consider adding an error boundary to your tree to customize error handling behavior.
Visit https://fb.me/react-error-boundaries to learn more about error boundaries.
C:\Users\nikla\Desktop\DEV\proton-hot-cli\node_modules\react-reconciler\cjs\react-reconciler.development.js:8568
    throw error;
    ^

Invariant Violation: 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.

Check the render method of `Wrapper`.
    at invariant (C:\Users\nikla\Desktop\DEV\proton-hot-cli\node_modules\fbjs\lib\invariant.js:42:15)
    at getFiberTagFromObjectType (C:\Users\nikla\Desktop\DEV\proton-hot-cli\node_modules\react-reconciler\cjs\react-reconciler.development.js:1589:9)
    at createFiberFromElement (C:\Users\nikla\Desktop\DEV\proton-hot-cli\node_modules\react-reconciler\cjs\react-reconciler.development.js:1549:20)
    at reconcileSingleElement (C:\Users\nikla\Desktop\DEV\proton-hot-cli\node_modules\react-reconciler\cjs\react-reconciler.development.js:4624:23)
    at reconcileChildFibers (C:\Users\nikla\Desktop\DEV\proton-hot-cli\node_modules\react-reconciler\cjs\react-reconciler.development.js:4680:35)
    at reconcileChildrenAtExpirationTime (C:\Users\nikla\Desktop\DEV\proton-hot-cli\node_modules\react-reconciler\cjs\react-reconciler.development.js:5051:28
)
    at finishClassComponent (C:\Users\nikla\Desktop\DEV\proton-hot-cli\node_modules\react-reconciler\cjs\react-reconciler.development.js:5253:3)
    at updateClassComponent (C:\Users\nikla\Desktop\DEV\proton-hot-cli\node_modules\react-reconciler\cjs\react-reconciler.development.js:5196:10)
    at beginWork (C:\Users\nikla\Desktop\DEV\proton-hot-cli\node_modules\react-reconciler\cjs\react-reconciler.development.js:5864:14)
    at performUnitOfWork (C:\Users\nikla\Desktop\DEV\proton-hot-cli\node_modules\react-reconciler\cjs\react-reconciler.development.js:7890:12)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.