Skip to content

Commit

Permalink
typescriptの基本
Browse files Browse the repository at this point in the history
  • Loading branch information
hoshi005 committed Aug 12, 2024
1 parent 047b87e commit 4ebbe7b
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions typescript/basic.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Typescriptの基本

- ブラウザで動作するのはjavascriptのみ
- javascriptの癖を隠蔽するための言語がaltJS
- altJSは、javascriptにコンパイルされて動作する
- altJSの例: TypeScript, CoffeeScript, Dart
- TypeScriptは、Microsoftが開発したaltJS

# node.js

- node.jsは、本来ブラウザでしか動作しないはずのjavascriptを、サーバーサイドで動作させるための環境
- npmは、node.jsのパッケージマネージャ
- typescriptは、npmのパッケージとして提供されている

```sh
# ローカルにインストールした場合は、npxを使う
npm install typescript
npx tsc --version

# グローバルにインストールした場合は、tscコマンドが使える
npm install -g typescript
tsc --version
```

0 comments on commit 4ebbe7b

Please sign in to comment.