mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-25 02:58:56 +01:00
API feedback (#162704)
* align bundle and uri value to be undefined together * Document everything
This commit is contained in:
committed by
GitHub
parent
d19445483e
commit
d942736bf1
@@ -2199,7 +2199,7 @@ export interface ExtHostTestingShape {
|
||||
|
||||
export interface ExtHostLocalizationShape {
|
||||
getMessage(extensionId: string, details: IStringDetails): string;
|
||||
getBundle(extensionId: string): { [key: string]: string };
|
||||
getBundle(extensionId: string): { [key: string]: string } | undefined;
|
||||
getBundleUri(extensionId: string): URI | undefined;
|
||||
initializeLocalizedMessages(extension: IExtensionDescription): Promise<void>;
|
||||
}
|
||||
|
||||
@@ -49,8 +49,8 @@ export class ExtHostLocalizationService implements ExtHostLocalizationShape {
|
||||
return format(str ?? key, ...(args ?? []));
|
||||
}
|
||||
|
||||
getBundle(extensionId: string): { [key: string]: string } {
|
||||
return this.bundleCache.get(extensionId)?.contents ?? {};
|
||||
getBundle(extensionId: string): { [key: string]: string } | undefined {
|
||||
return this.bundleCache.get(extensionId)?.contents;
|
||||
}
|
||||
|
||||
getBundleUri(extensionId: string): URI | undefined {
|
||||
|
||||
Reference in New Issue
Block a user