Enum tsconfig::Lib

source ·
pub enum Lib {
Show 42 variants Es5, Es2015, Es6, Es2016, Es7, Es2017, Es2018, Es2019, Es2020, EsNext, Dom, WebWorker, ScriptHost, DomIterable, Es2015Core, Es2015Generator, Es2015Iterable, Es2015Promise, Es2015Proxy, Es2015Reflect, Es2015Symbol, Es2015SymbolWellKnown, Es2016ArrayInclude, Es2017Object, Es2017Intl, Es2017SharedMemory, Es2017String, Es2017TypedArrays, Es2018Intl, Es2018Promise, Es2018RegExp, Es2019Array, Es2019Object, Es2019String, Es2019Symbol, Es2020String, Es2020SymbolWellknown, EsNextAsyncIterable, EsNextArray, EsNextIntl, EsNextSymbol, Other(String),
}
Expand description

Available definitions for built-in JS APIs.

TypeScript includes a default set of type definitions for built-in JS APIs (like Math), as well as type definitions for things found in browser environments (like document). TypeScript also includes APIs for newer JS features matching the target you specify; for example the definition for Map is available if target is ES6 or newer.

You may want to change these for a few reasons:

  • Your program doesn’t run in a browser, so you don’t want the “dom” type definitions
  • Your runtime platform provides certain JavaScript API objects (maybe through polyfills), but doesn’t yet support the full syntax of a given ECMAScript version
  • You have polyfills or native implementations for some, but not all, of a higher level ECMAScript version

Variants§

§

Es5

§

Es2015

§

Es6

§

Es2016

§

Es7

§

Es2017

§

Es2018

§

Es2019

§

Es2020

§

EsNext

§

Dom

§

WebWorker

§

ScriptHost

§

DomIterable

§

Es2015Core

§

Es2015Generator

§

Es2015Iterable

§

Es2015Promise

§

Es2015Proxy

§

Es2015Reflect

§

Es2015Symbol

§

Es2015SymbolWellKnown

§

Es2016ArrayInclude

§

Es2017Object

§

Es2017Intl

§

Es2017SharedMemory

§

Es2017String

§

Es2017TypedArrays

§

Es2018Intl

§

Es2018Promise

§

Es2018RegExp

§

Es2019Array

§

Es2019Object

§

Es2019String

§

Es2019Symbol

§

Es2020String

§

Es2020SymbolWellknown

§

EsNextAsyncIterable

§

EsNextArray

§

EsNextIntl

§

EsNextSymbol

§

Other(String)

Trait Implementations§

source§

impl Clone for Lib

source§

fn clone(&self) -> Lib

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Lib

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Lib

source§

fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
where D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl PartialEq for Lib

source§

fn eq(&self, other: &Lib) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl StructuralPartialEq for Lib

Auto Trait Implementations§

§

impl RefUnwindSafe for Lib

§

impl Send for Lib

§

impl Sync for Lib

§

impl Unpin for Lib

§

impl UnwindSafe for Lib

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,