Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>Typescript React TemplateNew to Visual Studio Code? Get it now.
Typescript React Template

Typescript React Template

Q

|
3,530 installs
| (0) | Free
Fills out a React Component template when you create a new TSX file
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Typescript React Template

If you create a new .tsx file called MyComponent.tsx, it'll initialize it with the following contents:

import * as React from "react";

export interface MyComponentProps {
}

export interface MyComponentState {
}

export class MyComponent extends React.PureComponent<MyComponentProps, MyComponentState> {
   render() {
       return (
           <div>
               Hello World
           </div>
       );
   }
}
  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft