Skip to main content

collect_references

Function collect_references 

Source
pub fn collect_references<R>(
    func: impl FnOnce() -> R,
) -> (R, HashSet<NamedReference>)
Expand description

This function collects all Typescript references which are created within the given closure.

This can be used for determining the imports required in a particular file.