Typescript Configuring

You might also like

Download as pdf
Download as pdf
You are on page 1of 1
Configuring TypeScript For your convenience, I have configured TypeScript in our repository. You can check it under src/chapter 11/¢xanpie 1 in the code files. There are a few things I want you to understand. ‘TypeScript comes with its own configuration file, called tscontig.json. In this file, you will find multiple configuration properties that control how strict the TypeScript compiler is. You can find a detailed list of the properties and explanations in the official documentation at ht tps://mn-typescriptiang-org/docs/hand book/compiler -options.htm. Among the options, you can find outoir. This specifies where the compiler output should be saved. In our repository, it is set to "outoir": "buita/aise*. Our application, from now on, will run the compiled code from the buiia/aist directory. Hence, I have changed the root app. js file as follows: // secl Chapter_1/ Exanple_a_TypeScript_support/ App.js inport Standaloneapp from './build/dist/Root'; inport StoryBookApp from '. /build/dist/storybook' ; Wn export default process. env['REACT_NATIVE_IS_STORY_B00K'] 7 StoryBookApp : Standalonesop; Now that you understand the configuration changes, we can now proceed with learning basic typing.

You might also like