react-workspaces / react-workspaces-playground

⚛️ 🐈 Zero Config Create-React-App Monorepos with Yarn Workspaces, Lerna and React Storybook.
https://react-workspaces.github.io/react-workspaces-playground/
764 stars 128 forks source link

Why @react-workspaces/react-scripts and react-scripts required as dependencies in same app #36

Open Jagatmachines opened 4 years ago

Jagatmachines commented 4 years ago

https://github.com/react-workspaces/react-workspaces-playground/blob/243028104739e7ecdc15488b199d80ab39d79fa5/packages/components-typescript/package.json#L24

F1LT3R commented 4 years ago

Well whoever committed that line was obviously an idiot.

Care to remove and submit PR?

alanrubin commented 4 years ago

Just a heads-up, I have removed react-scripts and starting getting issues with import of svg files, after some research I found that https://github.com/facebook/create-react-app/issues/8223

That means that after you remove the react-scripts, you will need to modify all react-app-env.d.ts files from:

/// <reference types="react-scripts" />

to

/// <reference types="@react-workspaces/react-scripts" />

After I have done that, the imports worked again. Obviously that is relevant only for people using Typescript.