Skip to content

fx-biocoder/typescript-notes

Repository files navigation

TypeScript Learning Notes

This repository contains a collection of TypeScript examples and notes covering fundamental concepts of the language. Each file focuses on specific TypeScript features with practical examples.

Contents

  1. Functions

    • Function expressions, declarations, and arrow functions
    • Optional and default parameters
    • Rest parameters
    • Function types
  2. Interfaces and Classes

    • Interface definitions and usage
    • Class declarations with access modifiers
    • Class implementation of interfaces
    • Constructor parameter properties
  3. Union and Intersection Types

    • Union types (|)
    • Intersection types (&)
    • Type guards and narrowing
    • Complex type combinations
  4. Type Aliases and Type Assertions

    • Creating type aliases
    • Complex type definitions
    • Type assertions using as and angle brackets
  5. Any, Unknown, and Never Types

    • Special TypeScript types
    • Type safety considerations

Getting Started

  1. Make sure you have Node.js installed
  2. Install TypeScript globally:
    npm install -g typescript
  3. Clone this repository
  4. Use tsc to compile the TypeScript files or run them directly with ts-node

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

  •  

Packages

 
 
 

Contributors