Npm.Scanner (LowEndInsight v0.6.5) View Source

Scanner scans for node dependencies to run analysis on.

Link to this section Summary

Functions

query_npm: function that takes in a package and returns an analysis on that package's repository using analyser_module. If the package url cannot be reached, an error is returned.

scan: called when node? is false, returning an empty list and 0

scan: takes in a path to node dependencies and returns the dependencies mapped to their analysis and the number of dependencies

Link to this section Functions

Specs

query_npm(String.t()) :: {:ok, map()} | String.t()

query_npm: function that takes in a package and returns an analysis on that package's repository using analyser_module. If the package url cannot be reached, an error is returned.

Link to this function

scan(node?, project_types)

View Source

Specs

scan(boolean(), map()) :: {[], [], 0}
scan(boolean(), %{node: []}) :: {[any()], [any()], non_neg_integer()}

scan: called when node? is false, returning an empty list and 0

Link to this function

scan(node?, map, option \\ ".")

View Source

scan: takes in a path to node dependencies and returns the dependencies mapped to their analysis and the number of dependencies