just-react icon indicating copy to clipboard operation
just-react copied to clipboard

在create-react-app创建的项目使用yarn link, yarn start 报错

Open xiayuegit opened this issue 4 years ago • 1 comments
trafficstars

/Users/xxxx/resource/project/front-end/github/react/packages/react/index.js:11 export type StatelessFunctionalComponent< ^^^^^^

SyntaxError: Unexpected token export at Module._compile (internal/modules/cjs/loader.js:721:23) at Object.Module._extensions..js (internal/modules/cjs/loader.js:787:10) at Module.load (internal/modules/cjs/loader.js:653:32) at tryModuleLoad (internal/modules/cjs/loader.js:593:12) at Function.Module._load (internal/modules/cjs/loader.js:585:3) at Module.require (internal/modules/cjs/loader.js:690:17) at require (internal/modules/cjs/helpers.js:25:18) at Object. (/Users/huanghao/resource/project/front-end/demo/a-react-demo/node_modules/react-scripts/scripts/start.js:52:15) at Module._compile (internal/modules/cjs/loader.js:776:30) at Object.Module._extensions..js (internal/modules/cjs/loader.js:787:10) error Command failed with exit code 1. info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

xiayuegit avatar Jan 05 '21 10:01 xiayuegit

使用 yarn build react/index,react/jsx,react-dom/index,scheduler --type=NODE 这个打包(官网上的)

wellssu0 avatar Feb 19 '21 13:02 wellssu0