Skip to main content

Module source_edits

Module source_edits 

Source
Expand description

Byte spans of the export statements of a file, for a surface that edits source text, such as the quick fix of the language server. The byte spans of the top-level export statements of a file, and the edits that remove their export keyword.

fallow fix, the language server and the CI review comments change source text. A line rule cannot tell which export keyword of a line belongs to a name, which names one keyword exports, or where a declaration ends. This module parses the file and answers these questions from the syntax tree. A file that does not parse gets no index, and so no edit.

Structs§

EnumSpans
One enum declaration with the spans of its members.
ExportStatement
One top-level export <declaration> or export default statement.
MemberSpan
One class element or enum member.
SourceEditIndex
The export statements and the class and enum members of one file text.
SpanEdit
One replacement of a byte range of the source text.

Enums§

EditRefusal
Why the index gives no statement for a request.
ExportStatementKind
The form of one export statement.