Closed
requested to merge github/fork/devloco/set-packageName-in-TypeScript-reference-file into master
Created by: devloco
This PR is sent as suggested by @Timer here: #5811 (closed)
Here are the full steps that I used to test:
- I published my react-scripts changes to NPM as
@devloco/react-scripts-test
- bash prompt at:
create-react-app/packages/create-react-app
-
npm link
(to pick up the changes made to createReactApp.js) cd ~/temp
create-react-app foo1 --typescript --scripts-version @devloco/react-scripts-test
- See app creation succeed.
cd foo1/src
vim react-app-env.d.ts
- See that "types" prop value is
@devloco/react-scripts-test
-
:q!
+ ENTER to exit vim yarn start
- See no errors happen. Webpack Dev Server and browser tab launch successfully. Page renders in browser as usual.
Make sure that not using --scripts-version still works the same
cd ~/temp
- `create-react-app foo2 --typescript
- See app creation succeed.
cd foo2/src
vim react-app-env.d.ts
- See that "types" prop value is
react-scripts
-
:q!
+ ENTER to exit vim yarn start
- See no errors happen. Webpack Dev Server and browser tab launch successfully. Page renders in browser as usual.