Base code when we want to start React project using Typescript
- Typescript config surprisingly easier and simpler to use rather than traditional webpack + babel + flow
- Typescript offer more features than flow and if we start new project and want typehint, using Typescript is more reasonable
yarn installyarn devto run in development mode with watched files
- Use
.tsfile extension for Typescript file - Use
.tsxfile extension for Typescript file that has React syntax
yarn installyarn lintyarn build- Load the
build/widget.jsin your server