Skip to main content

Module suggestions

Module suggestions 

Source
Expand description

Error Suggestions

Provides “did you mean?” suggestions for type errors using Levenshtein distance to find similar names when users make typos.

Functions§

find_similar
Find similar strings from a list of candidates.
format_suggestion
Format a “did you mean?” suggestion.
levenshtein_distance
Calculate the Levenshtein edit distance between two strings.
reasonable_max_distance
Calculate a reasonable max distance for suggestions based on target length.
suggest_function
Suggestion for an undefined function.
suggest_property
Suggestion for an unknown property.
suggest_variable
Suggestion for an undefined variable.