Giter Site home page Giter Site logo

typescript-adding-3rd-party-libs's Introduction

TypeScript-Adding-3rd-Party-Libs

Third party libraries when writing code help us add functionality and details that let's our code do what we want it to do. Within this Repo, I will be exploring Normal libraries that are able to be used in JavaScript & TypeScript and TypeScript-Specific libraries.

Normal Libraries

To utilize any JavaScript normal library there are added dependencies to make sure TypeScript can read the file.

Using "declare"

Normal JavaScript libraries require @types to be defined to be read and compiled by TypeScript. In some cases, these are not available. When that happens declare is utilized. This allows a user to force TypeScript to recognize variables or features that exist.

Lodash Library

Lodash is a JavaScript library that helps with managing methods that utilize priminitive and non-primitive data types. Required Type package that will indicate to TypeScript how to read the installed library. npm i --save-dev @types/lodash These installations includ d.ts files that contain how file works and how TS will read it.

Class Transformer

Class transformer is a third party library that targets classes.

Required npm i class-transformer --save-dev npm i reflect-metadata --save

Class Validator

Builds up on TypeScript Decorators. Adds validation rules within a class and will automatically validate. npm i class-validator --save

typescript-adding-3rd-party-libs's People

Contributors

jjayjack avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.