dsherret / dax

Cross-platform shell tools for Deno and Node.js inspired by zx.
MIT License
997 stars 34 forks source link

perf(path_ref): cache if the path is known to be resolved #107

Closed dsherret closed 1 year ago

dsherret commented 1 year ago

This stores a boolean in the path ref to know that it's resolved. It's about 200ns faster on a short path I measured (will be even faster for longer paths) and returns back this when the current PathRef is already resolved and no path segments are provided.