biome_js_parser 0.5.7

Biome's JavaScript parser
Documentation
JsModule {
    bom_token: missing (optional),
    interpreter_token: missing (optional),
    directives: JsDirectiveList [],
    items: JsModuleItemList [
        JsExport {
            decorators: JsDecoratorList [],
            export_token: EXPORT_KW@0..7 "export" [] [Whitespace(" ")],
            export_clause: TsExportDeclareClause {
                declare_token: DECLARE_KW@7..15 "declare" [] [Whitespace(" ")],
                declaration: JsVariableDeclarationClause {
                    declaration: JsVariableDeclaration {
                        await_token: missing (optional),
                        kind: CONST_KW@15..21 "const" [] [Whitespace(" ")],
                        declarators: JsVariableDeclaratorList [
                            JsVariableDeclarator {
                                id: JsIdentifierBinding {
                                    name_token: IDENT@21..22 "a" [] [],
                                },
                                variable_annotation: TsTypeAnnotation {
                                    colon_token: COLON@22..24 ":" [] [Whitespace(" ")],
                                    ty: TsStringType {
                                        string_token: STRING_KW@24..30 "string" [] [],
                                    },
                                },
                                initializer: missing (optional),
                            },
                        ],
                    },
                    semicolon_token: SEMICOLON@30..31 ";" [] [],
                },
            },
        },
        JsExport {
            decorators: JsDecoratorList [],
            export_token: EXPORT_KW@31..39 "export" [Newline("\n")] [Whitespace(" ")],
            export_clause: TsExportDeclareClause {
                declare_token: DECLARE_KW@39..47 "declare" [] [Whitespace(" ")],
                declaration: TsInterfaceDeclaration {
                    interface_token: INTERFACE_KW@47..57 "interface" [] [Whitespace(" ")],
                    id: TsIdentifierBinding {
                        name_token: IDENT@57..59 "A" [] [Whitespace(" ")],
                    },
                    type_parameters: missing (optional),
                    extends_clause: missing (optional),
                    l_curly_token: L_CURLY@59..60 "{" [] [],
                    members: TsTypeMemberList [],
                    r_curly_token: R_CURLY@60..61 "}" [] [],
                },
            },
        },
        JsExport {
            decorators: JsDecoratorList [],
            export_token: EXPORT_KW@61..69 "export" [Newline("\n")] [Whitespace(" ")],
            export_clause: TsExportDeclareClause {
                declare_token: DECLARE_KW@69..77 "declare" [] [Whitespace(" ")],
                declaration: TsEnumDeclaration {
                    const_token: missing (optional),
                    enum_token: ENUM_KW@77..82 "enum" [] [Whitespace(" ")],
                    id: JsIdentifierBinding {
                        name_token: IDENT@82..84 "B" [] [Whitespace(" ")],
                    },
                    l_curly_token: L_CURLY@84..85 "{" [] [],
                    members: TsEnumMemberList [],
                    r_curly_token: R_CURLY@85..86 "}" [] [],
                },
            },
        },
        JsExport {
            decorators: JsDecoratorList [],
            export_token: EXPORT_KW@86..94 "export" [Newline("\n")] [Whitespace(" ")],
            export_clause: TsExportDeclareClause {
                declare_token: DECLARE_KW@94..102 "declare" [] [Whitespace(" ")],
                declaration: TsTypeAliasDeclaration {
                    type_token: TYPE_KW@102..107 "type" [] [Whitespace(" ")],
                    binding_identifier: TsIdentifierBinding {
                        name_token: IDENT@107..109 "C" [] [Whitespace(" ")],
                    },
                    type_parameters: missing (optional),
                    eq_token: EQ@109..111 "=" [] [Whitespace(" ")],
                    ty: TsStringType {
                        string_token: STRING_KW@111..117 "string" [] [],
                    },
                    semicolon_token: SEMICOLON@117..118 ";" [] [],
                },
            },
        },
        JsExport {
            decorators: JsDecoratorList [],
            export_token: EXPORT_KW@118..126 "export" [Newline("\n")] [Whitespace(" ")],
            export_clause: TsExportDeclareClause {
                declare_token: DECLARE_KW@126..134 "declare" [] [Whitespace(" ")],
                declaration: JsClassDeclaration {
                    decorators: JsDecoratorList [],
                    abstract_token: missing (optional),
                    class_token: CLASS_KW@134..140 "class" [] [Whitespace(" ")],
                    id: JsIdentifierBinding {
                        name_token: IDENT@140..142 "D" [] [Whitespace(" ")],
                    },
                    type_parameters: missing (optional),
                    extends_clause: missing (optional),
                    implements_clause: missing (optional),
                    l_curly_token: L_CURLY@142..143 "{" [] [],
                    members: JsClassMemberList [],
                    r_curly_token: R_CURLY@143..144 "}" [] [],
                },
            },
        },
        JsExport {
            decorators: JsDecoratorList [],
            export_token: EXPORT_KW@144..152 "export" [Newline("\n")] [Whitespace(" ")],
            export_clause: TsExportDeclareClause {
                declare_token: DECLARE_KW@152..160 "declare" [] [Whitespace(" ")],
                declaration: TsDeclareFunctionDeclaration {
                    async_token: missing (optional),
                    function_token: FUNCTION_KW@160..169 "function" [] [Whitespace(" ")],
                    id: JsIdentifierBinding {
                        name_token: IDENT@169..170 "e" [] [],
                    },
                    type_parameters: missing (optional),
                    parameters: JsParameters {
                        l_paren_token: L_PAREN@170..171 "(" [] [],
                        items: JsParameterList [],
                        r_paren_token: R_PAREN@171..172 ")" [] [],
                    },
                    return_type_annotation: missing (optional),
                    semicolon_token: missing (optional),
                },
            },
        },
    ],
    eof_token: EOF@172..173 "" [Newline("\n")] [],
}

0: JS_MODULE@0..173
  0: (empty)
  1: (empty)
  2: JS_DIRECTIVE_LIST@0..0
  3: JS_MODULE_ITEM_LIST@0..172
    0: JS_EXPORT@0..31
      0: JS_DECORATOR_LIST@0..0
      1: EXPORT_KW@0..7 "export" [] [Whitespace(" ")]
      2: TS_EXPORT_DECLARE_CLAUSE@7..31
        0: DECLARE_KW@7..15 "declare" [] [Whitespace(" ")]
        1: JS_VARIABLE_DECLARATION_CLAUSE@15..31
          0: JS_VARIABLE_DECLARATION@15..30
            0: (empty)
            1: CONST_KW@15..21 "const" [] [Whitespace(" ")]
            2: JS_VARIABLE_DECLARATOR_LIST@21..30
              0: JS_VARIABLE_DECLARATOR@21..30
                0: JS_IDENTIFIER_BINDING@21..22
                  0: IDENT@21..22 "a" [] []
                1: TS_TYPE_ANNOTATION@22..30
                  0: COLON@22..24 ":" [] [Whitespace(" ")]
                  1: TS_STRING_TYPE@24..30
                    0: STRING_KW@24..30 "string" [] []
                2: (empty)
          1: SEMICOLON@30..31 ";" [] []
    1: JS_EXPORT@31..61
      0: JS_DECORATOR_LIST@31..31
      1: EXPORT_KW@31..39 "export" [Newline("\n")] [Whitespace(" ")]
      2: TS_EXPORT_DECLARE_CLAUSE@39..61
        0: DECLARE_KW@39..47 "declare" [] [Whitespace(" ")]
        1: TS_INTERFACE_DECLARATION@47..61
          0: INTERFACE_KW@47..57 "interface" [] [Whitespace(" ")]
          1: TS_IDENTIFIER_BINDING@57..59
            0: IDENT@57..59 "A" [] [Whitespace(" ")]
          2: (empty)
          3: (empty)
          4: L_CURLY@59..60 "{" [] []
          5: TS_TYPE_MEMBER_LIST@60..60
          6: R_CURLY@60..61 "}" [] []
    2: JS_EXPORT@61..86
      0: JS_DECORATOR_LIST@61..61
      1: EXPORT_KW@61..69 "export" [Newline("\n")] [Whitespace(" ")]
      2: TS_EXPORT_DECLARE_CLAUSE@69..86
        0: DECLARE_KW@69..77 "declare" [] [Whitespace(" ")]
        1: TS_ENUM_DECLARATION@77..86
          0: (empty)
          1: ENUM_KW@77..82 "enum" [] [Whitespace(" ")]
          2: JS_IDENTIFIER_BINDING@82..84
            0: IDENT@82..84 "B" [] [Whitespace(" ")]
          3: L_CURLY@84..85 "{" [] []
          4: TS_ENUM_MEMBER_LIST@85..85
          5: R_CURLY@85..86 "}" [] []
    3: JS_EXPORT@86..118
      0: JS_DECORATOR_LIST@86..86
      1: EXPORT_KW@86..94 "export" [Newline("\n")] [Whitespace(" ")]
      2: TS_EXPORT_DECLARE_CLAUSE@94..118
        0: DECLARE_KW@94..102 "declare" [] [Whitespace(" ")]
        1: TS_TYPE_ALIAS_DECLARATION@102..118
          0: TYPE_KW@102..107 "type" [] [Whitespace(" ")]
          1: TS_IDENTIFIER_BINDING@107..109
            0: IDENT@107..109 "C" [] [Whitespace(" ")]
          2: (empty)
          3: EQ@109..111 "=" [] [Whitespace(" ")]
          4: TS_STRING_TYPE@111..117
            0: STRING_KW@111..117 "string" [] []
          5: SEMICOLON@117..118 ";" [] []
    4: JS_EXPORT@118..144
      0: JS_DECORATOR_LIST@118..118
      1: EXPORT_KW@118..126 "export" [Newline("\n")] [Whitespace(" ")]
      2: TS_EXPORT_DECLARE_CLAUSE@126..144
        0: DECLARE_KW@126..134 "declare" [] [Whitespace(" ")]
        1: JS_CLASS_DECLARATION@134..144
          0: JS_DECORATOR_LIST@134..134
          1: (empty)
          2: CLASS_KW@134..140 "class" [] [Whitespace(" ")]
          3: JS_IDENTIFIER_BINDING@140..142
            0: IDENT@140..142 "D" [] [Whitespace(" ")]
          4: (empty)
          5: (empty)
          6: (empty)
          7: L_CURLY@142..143 "{" [] []
          8: JS_CLASS_MEMBER_LIST@143..143
          9: R_CURLY@143..144 "}" [] []
    5: JS_EXPORT@144..172
      0: JS_DECORATOR_LIST@144..144
      1: EXPORT_KW@144..152 "export" [Newline("\n")] [Whitespace(" ")]
      2: TS_EXPORT_DECLARE_CLAUSE@152..172
        0: DECLARE_KW@152..160 "declare" [] [Whitespace(" ")]
        1: TS_DECLARE_FUNCTION_DECLARATION@160..172
          0: (empty)
          1: FUNCTION_KW@160..169 "function" [] [Whitespace(" ")]
          2: JS_IDENTIFIER_BINDING@169..170
            0: IDENT@169..170 "e" [] []
          3: (empty)
          4: JS_PARAMETERS@170..172
            0: L_PAREN@170..171 "(" [] []
            1: JS_PARAMETER_LIST@171..171
            2: R_PAREN@171..172 ")" [] []
          5: (empty)
          6: (empty)
  4: EOF@172..173 "" [Newline("\n")] []