@@ -21,15 +21,16 @@ import { KeywordHoverRegistry } from './hover/KeywordHoverRegistry.js'
2121import { ContextMapperDslNodeKindProvider } from './shared/ContextMapperDslNodeKindProvider.js'
2222import { ContextMapperDslFormatter } from './formatting/ContextMapperDslFormatter.js'
2323import { ContextMapperFormatterRegistry } from './formatting/ContextMapperFormatterRegistry.js'
24+ import { ContextMapperDslCompletionProvider } from './completion/ContextMapperDslCompletionProvider.js'
2425
2526/**
2627 * Declaration of custom services - add your own service classes here.
2728 */
28- export type ContextMapperDslAddedServices = {
29+ export interface ContextMapperDslAddedServices {
2930 validation : {
3031 ContextMapperDslValidator : ContextMapperDslValidator
3132 }
32- } ;
33+ }
3334
3435/**
3536 * Union of Langium default services and your custom services - use this as constructor parameter
@@ -57,7 +58,8 @@ export const ContextMapperDslModule: Module<ContextMapperDslServices, ModuleType
5758 SemanticTokenProvider : ( services ) => new ContextMapperDslSemanticTokenProvider ( services , semanticTokenProviderRegistry ) ,
5859 FoldingRangeProvider : ( services ) => new ContextMapperDslFoldingRangeProvider ( services ) ,
5960 HoverProvider : ( services ) => new ContextMapperDslHoverProvider ( services , new KeywordHoverRegistry ( ) ) ,
60- Formatter : ( ) => new ContextMapperDslFormatter ( new ContextMapperFormatterRegistry ( ) )
61+ Formatter : ( ) => new ContextMapperDslFormatter ( new ContextMapperFormatterRegistry ( ) ) ,
62+ CompletionProvider : ( services ) => new ContextMapperDslCompletionProvider ( services )
6163 } ,
6264 references : {
6365 ScopeProvider : ( services ) => new ContextMapperDslScopeProvider ( services ) ,
@@ -102,7 +104,7 @@ export function createContextMapperDslServices (context: DefaultSharedModuleCont
102104 if ( ! context . connection ) {
103105 // We don't run inside a language server
104106 // Therefore, initialize the configuration provider instantly
105- shared . workspace . ConfigurationProvider . initialized ( { } )
107+ void shared . workspace . ConfigurationProvider . initialized ( { } )
106108 }
107109 return { shared, ContextMapperDsl }
108110}
0 commit comments