Cargo Features

swc_ecma_loader has no features set by default.

[dependencies]
swc_ecma_loader = { version = "0.45.20", features = ["cache", "node", "tsc"] }
cache = lru, parking_lot
node = dashmap, normpath, once_cell, path-clean, serde_json

Enable node js resolver

Affects resolvers::node

tsc = dashmap, once_cell, swc_cached

Enable support for paths of tsconfig.json

Affects resolvers::tsc

Features from optional dependencies

In crates that don't use the dep: syntax, optional dependencies automatically become Cargo features.

dashmap node? tsc?
lru cache?

Enables lru ^0.10.0

Affects resolvers::lru

once_cell node? tsc?
parking_lot cache?
path-clean node?

Enables path-clean =0.1.0

serde_json node?
swc_cached tsc?
normpath win node?

Enables normpath ^0.2