当前位置:网站首页>"21 days proficient in typescript-3" - install and build a typescript development environment md
"21 days proficient in typescript-3" - install and build a typescript development environment md
2022-07-05 16:26:00 【Do front-end Pinellia ternata】
Hello everyone , I am Pinellia ternata , A sand carving programmer who just started writing . If you like my article , Can pay attention to give the thumbs-up
Add me WeChat :frontendpicker, Learn to communicate together , Become a better Engineer ~ Official account : Pinellia ternata ,
Column address
In order to make the world not difficult to learn TypeScript, The author is reading the official documents ,MDN On the basis of , With Meeting and use For the fundamental goal , Take you to learn TypeScript Basic knowledge of ! This column , No article cap , Always more , Until everyone learns .
https://blog.csdn.net/shangyanaf/category_11822476.html
install TypeScript
As a front-end Developer , We can use the following command overall situation Fast installation TypeScript.
npm install typescript -g
Open the command line window , for example windows Under the cmd.


tsc
TypeScript Command line tools are provided tsc.
TypeScript Files cannot be run directly in the browser , We need to convert it into JavaScript file .
tsc The role of will be TypeScrpt file **(.ts)** Translate it into JavaScript file (.js).
Verify that the installation was successful / View version number :
tsc -V

Editor
In addition to command line tools ,TypeScript The editor and IDE The function of , Including code completion 、 Interface tips 、 Jump to definition 、 Reconstruction, etc .
Mainstream editors support TypeScript, Here I recommend Visual Studio Code(VsCode).VsCode Built in right TypeScript Grammar check .
If you use it often VSCode, You may occasionally put your mouse over variables , here VSCode A prompt box will be given above the variable .
The effect is shown in the red box below , Tips let userName:string,userName yes string Type of . This is actually TS Type inference of .

Get another editor or IDE Yes TypeScript Support for :
- Sublime Text
- WebStorm
- Vim
- Emacs
- Eclipse
- Atom
- [Visual Studio 2019](https://marketplace.visualstudio.com/search?term=TypeScriptTeam&target=VS&category=All categories&vsVersion=vs2019&sortBy=UpdatedDate)
- [Visual Studio 2017](https://marketplace.visualstudio.com/search?term=TypeScriptTeam&target=VS&category=All categories&vsVersion=vs15&sortBy=UpdatedDate)
typeScript Online tools
If you are practicing TypeScript grammar , You can use it directly TypeScript Online tools provided .
https://www.typescriptlang.org/zh/play

边栏推荐
- Single merchant v4.4 has the same original intention and strength!
- 漫画:什么是MapReduce?
- sql中查询最近一条记录
- 怎样在电脑上设置路由器的WiFi密码
- Today's sleep quality record 79 points
- Dataarts studio data architecture - Introduction to data standards
- tf.sequence_mask函数讲解案例
- 【毕业季】作为一名大二计科在校生,我有话想说
- CISP-PTE之PHP伪协议总结
- The difference between abstract classes and interfaces
猜你喜欢

数据湖(十四):Spark与Iceberg整合查询操作

ES6深入—ES6 Generator 函数

【网易云信】超分辨率技术在实时音视频领域的研究与实践
Intel 13th generation Raptor Lake processor information exposure: more cores, larger cache

Seaborn draws 11 histograms

Parameter type setting error during batch update in project SQL

PSPNet | 语义分割及场景分析

Subclasses and superclasses of abstract classes

降本40%!Redis多租户集群的容器化实践

The new version of effect editor is online! 3D rendering, labeling, and animation, this time an editor is enough
随机推荐
List de duplication and count the number
APICloud云调试解决方案
给自己打打气
项目中批量update
极坐标扇图使用场景与功能详解
详解SQL中Groupings Sets 语句的功能和底层实现逻辑
Quick completion guide for manipulator (IX): forward kinematics analysis
《MongoDB入门教程》第04篇 MongoDB客户端
Query the latest record in SQL
list集合根据对象某属性求和,最大值等
Practice independent and controllable 3.0 and truly create the open source business of the Chinese people
ES6 deep - ES6 class class
sql中set标签的使用
ES6深入—ES6 Class 类
新春限定丨“牛年忘烦”礼包等你来领~
Reduce the cost by 40%! Container practice of redis multi tenant cluster
Five common negotiation strategies of consulting companies and how to safeguard their own interests
漫画:什么是MapReduce?
Dataarts studio data architecture - Introduction to data standards
Boost the development of digital economy and consolidate the base of digital talents - the digital talent competition was successfully held in Kunming