@@ -19,22 +19,21 @@ interface MinimizeOptions {
1919}
2020
2121export function generate_llm_content ( options : GenerateLlmContentOptions = { } ) : string {
22- const { prefix, ignore = [ ] , minimize : minimizeOptions , package : pkg } = options ;
23-
2422 let content = '' ;
25- if ( prefix ) {
26- content = `${ prefix } \n\n` ;
23+
24+ if ( options . prefix ) {
25+ content = `${ options . prefix } \n\n` ;
2726 }
2827
2928 let current_section = '' ;
3029 const paths = sort_documentation_paths ( ) ;
3130
3231 for ( const path of paths ) {
33- if ( ! should_include_file_llm_docs ( path , ignore ) ) continue ;
32+ if ( ! should_include_file_llm_docs ( path , options . ignore ) ) continue ;
3433
3534 // If a specific package is provided, only include its docs
36- if ( pkg ) {
37- if ( ! path . includes ( `docs/${ pkg } /` ) ) continue ;
35+ if ( options . package ) {
36+ if ( ! path . includes ( `docs/${ options . package } /` ) ) continue ;
3837 } else {
3938 // For combined content, only include paths that match any package
4039 const doc_type = packages . find ( ( p ) => path . includes ( `docs/${ p } /` ) ) ;
@@ -48,8 +47,8 @@ export function generate_llm_content(options: GenerateLlmContentOptions = {}): s
4847 }
4948 }
5049
51- const docContent = minimizeOptions
52- ? minimize_content ( index [ path ] . body , minimizeOptions )
50+ const docContent = options . minimize
51+ ? minimize_content ( index [ path ] . body , options . minimize )
5352 : index [ path ] . body ;
5453 if ( docContent . trim ( ) === '' ) continue ;
5554
0 commit comments