Enum swc_ecma_preset_env::Feature[][src]

pub enum Feature {
    TemplateLiterals,
    Literals,
    FunctionName,
    ArrowFunctions,
    BlockScopedFunctions,
    Classes,
    ObjectSuper,
    ShorthandProperties,
    DuplicateKeys,
    ComputedProperties,
    ForOf,
    StickyRegex,
    DotAllRegex,
    UnicodeRegex,
    Spread,
    Parameters,
    Destructuring,
    BlockScoping,
    TypeOfSymbol,
    NewTarget,
    Regenerator,
    ExponentiationOperator,
    AsyncToGenerator,
    AsyncGeneratorFunctions,
    ObjectRestSpread,
    UnicodePropertyRegex,
    JsonStrings,
    OptionalCatchBinding,
    NamedCapturingGroupsRegex,
    MemberExpressionLiterals,
    PropertyLiterals,
    ReservedWords,
    NullishCoalescing,
    OptionalChaining,
    ClassProperties,
    NumericSeparator,
    PrivateMethods,
    UnicodeEscapes,
    BugfixAsyncArrowsInClass,
    BugfixEdgeDefaultParam,
    BugfixTaggedTemplateCaching,
}

Variants

TemplateLiterals

transform-template-literals

Literals

transform-literals

FunctionName

transform-function-name

ArrowFunctions

transform-arrow-functions

BlockScopedFunctions

transform-block-scoped-functions

Classes

transform-classes

ObjectSuper

transform-object-super

ShorthandProperties

transform-shorthand-properties

DuplicateKeys

transform-duplicate-keys

ComputedProperties

transform-computed-properties

ForOf

transform-for-of

StickyRegex

transform-sticky-regex

DotAllRegex

transform-dotall-regex

UnicodeRegex

transform-unicode-regex

Spread

transform-spread

Parameters

transform-parameters

Destructuring

transform-destructuring

BlockScoping

transform-block-scoping

TypeOfSymbol

transform-typeof-symbol

NewTarget

transform-new-target

Regenerator

transform-regenerator

ExponentiationOperator

transform-exponentiation-operator

AsyncToGenerator

transform-async-to-generator

AsyncGeneratorFunctions

proposal-async-generator-functions

ObjectRestSpread

proposal-object-rest-spread

UnicodePropertyRegex

proposal-unicode-property-regex

JsonStrings

proposal-json-strings

OptionalCatchBinding

proposal-optional-catch-binding

NamedCapturingGroupsRegex

transform-named-capturing-groups-regex

MemberExpressionLiterals

transform-member-expression-literals

PropertyLiterals

transform-property-literals

ReservedWords

transform-reserved-words

NullishCoalescing

proposal-nullish-coalescing-operator

OptionalChaining

proposal-optional-chaining

ClassProperties

proposal-class-properties

NumericSeparator

proposal-numeric-separator

PrivateMethods

proposal-private-methods

UnicodeEscapes

transform-unicode-escapes

BugfixAsyncArrowsInClass

bugfix/transform-async-arrows-in-class

BugfixEdgeDefaultParam

bugfix/transform-edge-default-parameters

BugfixTaggedTemplateCaching

bugfix/transform-tagged-template-caching

Implementations

impl Feature[src]

pub fn should_enable(
    self,
    target: Versions,
    bugfixes: bool,
    default: bool
) -> bool
[src]

impl Feature[src]

pub fn as_str(&self) -> &'static str[src]

Trait Implementations

impl Clone for Feature[src]

impl Copy for Feature[src]

impl Debug for Feature[src]

impl<'de> Deserialize<'de> for Feature[src]

impl Display for Feature[src]

impl Eq for Feature[src]

impl From<Feature> for FeatureOrModule[src]

impl FromStr for Feature[src]

type Err = ()

The associated error which can be returned from parsing.

impl Hash for Feature[src]

impl PartialEq<Feature> for Feature[src]

impl Serialize for Feature[src]

impl StructuralEq for Feature[src]

impl StructuralPartialEq for Feature[src]

Auto Trait Implementations

impl RefUnwindSafe for Feature

impl Send for Feature

impl Sync for Feature

impl Unpin for Feature

impl UnwindSafe for Feature

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

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

impl<Q, K> Equivalent<K> for Q where
    K: Borrow<Q> + ?Sized,
    Q: Eq + ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Node for T where
    T: Any + ?Sized
[src]

impl<T> Send for T where
    T: ?Sized
[src]

impl<T> Sync for T where
    T: ?Sized
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.