From d4791fa38bfa5054f77a5abae1359594d7392b20 Mon Sep 17 00:00:00 2001
From: Alex Jerabek <38896772+AlexJerabek@users.noreply.github.com>
Date: Tue, 24 Feb 2026 08:40:26 -0800
Subject: [PATCH] [office-js. office-js-preview] Add code styling to
Office.Settings (#74553)
---
types/office-js-preview/index.d.ts | 100 +++++++++++++--------------
types/office-js/index.d.ts | 104 ++++++++++++++---------------
2 files changed, 102 insertions(+), 102 deletions(-)
diff --git a/types/office-js-preview/index.d.ts b/types/office-js-preview/index.d.ts
index 489e031b4c6e6d..5d464c1e3c7a80 100644
--- a/types/office-js-preview/index.d.ts
+++ b/types/office-js-preview/index.d.ts
@@ -7922,17 +7922,17 @@ declare namespace Office {
*/
interface Settings {
/**
- * Adds an event handler for the settingsChanged event.
+ * Adds an event handler for the `settingsChanged` event.
*
- * **Important**: Your add-in's code can register a handler for the settingsChanged event when the add-in is running with any Excel client, but
+ * **Important**: Your add-in's code can register a handler for the `settingsChanged` event when the add-in is running with any Excel client, but
* the event will fire only when the add-in is loaded with a spreadsheet that is opened in Excel on the web, and more than one user is editing the
- * spreadsheet (coauthoring). Therefore, effectively the settingsChanged event is supported only in Excel on the web in coauthoring scenarios.
+ * spreadsheet (coauthoring). Therefore, effectively the `settingsChanged` event is supported only in Excel on the web in coauthoring scenarios.
*
* @remarks
*
* **Requirement set**: {@link https://learn.microsoft.com/javascript/api/requirement-sets/common/office-add-in-requirement-sets#methods-that-arent-part-of-a-requirement-set | Not in a set}
*
- * You can add multiple event handlers for the specified eventType as long as the name of each event handler function is unique.
+ * You can add multiple event handlers for the specified `eventType` as long as the name of each event handler function is unique.
*
* @param eventType Specifies the type of event to add. Required.
* @param handler The event handler function to add, whose only parameter is of type {@link Office.SettingsChangedEventArgs}. Required.
@@ -7954,27 +7954,27 @@ declare namespace Office {
*
*
* AsyncResult.error |
- * Access an Error object that provides error information if the operation failed. |
+ * Access an Error object that provides error information if the operation failed. |
*
*
* AsyncResult.asyncContext |
- * Define an item of any type that's returned in the AsyncResult object without being altered. |
+ * Define an item of any type that's returned in the AsyncResult object without being altered. |
*
*
*/
addHandlerAsync(eventType: Office.EventType, handler: any, options?: Office.AsyncContextOptions, callback?: (result: AsyncResult) => void): void;
/**
- * Adds an event handler for the settingsChanged event.
+ * Adds an event handler for the `settingsChanged` event.
*
- * **Important**: Your add-in's code can register a handler for the settingsChanged event when the add-in is running with any Excel client, but
+ * **Important**: Your add-in's code can register a handler for the `settingsChanged` event when the add-in is running with any Excel client, but
* the event will fire only when the add-in is loaded with a spreadsheet that is opened in Excel on the web, and more than one user is editing the
- * spreadsheet (coauthoring). Therefore, effectively the settingsChanged event is supported only in Excel on the web in coauthoring scenarios.
+ * spreadsheet (coauthoring). Therefore, effectively the `settingsChanged` event is supported only in Excel on the web in coauthoring scenarios.
*
* @remarks
*
* **Requirement set**: {@link https://learn.microsoft.com/javascript/api/requirement-sets/common/office-add-in-requirement-sets#methods-that-arent-part-of-a-requirement-set | Not in a set}
*
- * You can add multiple event handlers for the specified eventType as long as the name of each event handler function is unique.
+ * You can add multiple event handlers for the specified `eventType` as long as the name of each event handler function is unique.
*
* @param eventType Specifies the type of event to add. Required.
* @param handler The event handler function to add, whose only parameter is of type {@link Office.SettingsChangedEventArgs}. Required.
@@ -7995,11 +7995,11 @@ declare namespace Office {
*
*
* AsyncResult.error |
- * Access an Error object that provides error information if the operation failed. |
+ * Access an Error object that provides error information if the operation failed. |
*
*
* AsyncResult.asyncContext |
- * Define an item of any type that's returned in the AsyncResult object without being altered. |
+ * Define an item of any type that's returned in the AsyncResult object without being altered. |
*
*
*/
@@ -8025,10 +8025,10 @@ declare namespace Office {
* This method is useful in Excel, Word, and PowerPoint coauthoring scenarios when multiple instances of the same add-in are working against
* the same document. Because each add-in is working against an in-memory copy of the settings loaded from the document at the time the user
* opened it, the settings values used by each user can get out of sync. This can happen whenever an instance of the add-in calls the
- * Settings.saveAsync method to persist all of that user's settings to the document. Calling the refreshAsync method from the event handler
- * for the settingsChanged event of the add-in will refresh the settings values for all users.
+ * `Settings.saveAsync` method to persist all of that user's settings to the document. Calling the `refreshAsync` method from the event handler
+ * for the `settingsChanged` event of the add-in will refresh the settings values for all users.
*
- * In the callback function passed to the refreshAsync method, you can use the properties of the AsyncResult object to return the following
+ * In the callback function passed to the `refreshAsync` method, you can use the properties of the `AsyncResult` object to return the following
* information.
*
*
@@ -8038,7 +8038,7 @@ declare namespace Office {
*
*
* AsyncResult.value |
- * Access a Settings object with the refreshed values. |
+ * Access a Settings object with the refreshed values. |
*
*
* AsyncResult.status |
@@ -8046,11 +8046,11 @@ declare namespace Office {
*
*
* AsyncResult.error |
- * Access an Error object that provides error information if the operation failed. |
+ * Access an Error object that provides error information if the operation failed. |
*
*
* AsyncResult.asyncContext |
- * Define an item of any type that's returned in the AsyncResult object without being altered. |
+ * Define an item of any type that's returned in the AsyncResult object without being altered. |
*
*
*
@@ -8061,33 +8061,33 @@ declare namespace Office {
/**
* Removes the specified setting.
*
- * **Important**: Be aware that the Settings.remove method affects only the in-memory copy of the settings property bag. To persist the removal of
- * the specified setting in the document, at some point after calling the Settings.remove method and before the add-in is closed, you must
- * call the Settings.saveAsync method.
+ * **Important**: Be aware that the `Settings.remove` method affects only the in-memory copy of the settings property bag. To persist the removal of
+ * the specified setting in the document, at some point after calling the `Settings.remove` method and before the add-in is closed, you must
+ * call the `Settings.saveAsync` method.
*
* @remarks
*
* **Requirement set**: {@link https://learn.microsoft.com/javascript/api/requirement-sets/common/office-add-in-requirement-sets#settings | Settings}
*
- * null is a valid value for a setting. Therefore, assigning null to the setting will not remove it from the settings property bag.
+ * `null` is a valid value for a setting. Therefore, assigning `null` to the setting will not remove it from the settings property bag.
*
* @param settingName The case-sensitive name of the setting to remove.
*/
remove(name: string): void;
/**
- * Removes an event handler for the settingsChanged event.
+ * Removes an event handler for the `settingsChanged` event.
*
* @remarks
*
* **Requirement set**: {@link https://learn.microsoft.com/javascript/api/requirement-sets/common/office-add-in-requirement-sets#methods-that-arent-part-of-a-requirement-set | Not in a set}
*
- * If the optional handler parameter is omitted when calling the removeHandlerAsync method, all event handlers for the specified eventType
+ * If the optional handler parameter is omitted when calling the `removeHandlerAsync` method, all event handlers for the specified `eventType`
* will be removed.
*
- * When the function you passed to the callback parameter executes, it receives an AsyncResult object that you can access from the callback
+ * When the function you passed to the callback parameter executes, it receives an `AsyncResult` object that you can access from the callback
* function's only parameter.
*
- * In the callback function passed to the removeHandlerAsync method, you can use the properties of the AsyncResult object to return the
+ * In the callback function passed to the `removeHandlerAsync` method, you can use the properties of the `AsyncResult` object to return the
* following information.
*
*
@@ -8105,11 +8105,11 @@ declare namespace Office {
*
*
* AsyncResult.error |
- * Access an Error object that provides error information if the operation failed. |
+ * Access an Error object that provides error information if the operation failed. |
*
*
* AsyncResult.asyncContext |
- * Define an item of any type that's returned in the AsyncResult object without being altered. |
+ * Define an item of any type that's returned in the AsyncResult object without being altered. |
*
*
*
@@ -8119,19 +8119,19 @@ declare namespace Office {
*/
removeHandlerAsync(eventType: Office.EventType, options?: RemoveHandlerOptions, callback?: (result: AsyncResult) => void): void;
/**
- * Removes an event handler for the settingsChanged event.
+ * Removes an event handler for the `settingsChanged` event.
*
* @remarks
*
* **Requirement set**: {@link https://learn.microsoft.com/javascript/api/requirement-sets/common/office-add-in-requirement-sets#methods-that-arent-part-of-a-requirement-set | Not in a set}
*
- * If the optional handler parameter is omitted when calling the removeHandlerAsync method, all event handlers for the specified eventType
+ * If the optional handler parameter is omitted when calling the `removeHandlerAsync` method, all event handlers for the specified `eventType`
* will be removed.
*
- * When the function you passed to the callback parameter executes, it receives an AsyncResult object that you can access from the callback
+ * When the function you passed to the callback parameter executes, it receives an `AsyncResult` object that you can access from the callback
* function's only parameter.
*
- * In the callback function passed to the removeHandlerAsync method, you can use the properties of the AsyncResult object to return the
+ * In the callback function passed to the `removeHandlerAsync` method, you can use the properties of the `AsyncResult` object to return the
* following information.
*
*
@@ -8149,11 +8149,11 @@ declare namespace Office {
*
*
* AsyncResult.error |
- * Access an Error object that provides error information if the operation failed. |
+ * Access an Error object that provides error information if the operation failed. |
*
*
* AsyncResult.asyncContext |
- * Define an item of any type that's returned in the AsyncResult object without being altered. |
+ * Define an item of any type that's returned in the AsyncResult object without being altered. |
*
*
*
@@ -8169,11 +8169,11 @@ declare namespace Office {
* **Requirement set**: {@link https://learn.microsoft.com/javascript/api/requirement-sets/common/office-add-in-requirement-sets#settings | Settings}
*
* Any settings previously saved by an add-in are loaded when it is initialized, so during the lifetime of the session you can just use the
- * set and get methods to work with the in-memory copy of the settings property bag. When you want to persist the settings so that they are
- * available the next time the add-in is used, use the saveAsync method.
+ * `set` and `get` methods to work with the in-memory copy of the settings property bag. When you want to persist the settings so that they are
+ * available the next time the add-in is used, use the `saveAsync` method.
*
- * **Note**: The saveAsync method persists the in-memory settings property bag into the document file. However, the changes to the document file
- * itself are saved only when the user (or AutoRecover setting) saves the document to the file system. The refreshAsync method is only useful
+ * **Note**: The `saveAsync` method persists the in-memory settings property bag into the document file. However, the changes to the document file
+ * itself are saved only when the user (or AutoRecover setting) saves the document to the file system. The `refreshAsync` method is only useful
* in coauthoring scenarios when other instances of the same add-in might change the settings and those changes should be made available to
* all instances.
*
@@ -8192,11 +8192,11 @@ declare namespace Office {
*
*
* AsyncResult.error |
- * Access an Error object that provides error information if the operation failed. |
+ * Access an Error object that provides error information if the operation failed. |
*
*
* AsyncResult.asyncContext |
- * Define an item of any type that's returned in the AsyncResult object without being altered. |
+ * Define an item of any type that's returned in the AsyncResult object without being altered. |
*
*
*
@@ -8212,11 +8212,11 @@ declare namespace Office {
* **Requirement set**: {@link https://learn.microsoft.com/javascript/api/requirement-sets/common/office-add-in-requirement-sets#settings | Settings}
*
* Any settings previously saved by an add-in are loaded when it is initialized, so during the lifetime of the session you can just use the
- * set and get methods to work with the in-memory copy of the settings property bag. When you want to persist the settings so that they are
- * available the next time the add-in is used, use the saveAsync method.
+ * `set` and `get` methods to work with the in-memory copy of the settings property bag. When you want to persist the settings so that they are
+ * available the next time the add-in is used, use the `saveAsync` method.
*
- * **Note**: The saveAsync method persists the in-memory settings property bag into the document file. However, the changes to the document file
- * itself are saved only when the user (or AutoRecover setting) saves the document to the file system. The refreshAsync method is only useful
+ * **Note**: The `saveAsync` method persists the in-memory settings property bag into the document file. However, the changes to the document file
+ * itself are saved only when the user (or AutoRecover setting) saves the document to the file system. The `refreshAsync` method is only useful
* in coauthoring scenarios when other instances of the same add-in might change the settings and those changes should be made available to
* all instances.
*
@@ -8235,11 +8235,11 @@ declare namespace Office {
*
*
* AsyncResult.error |
- * Access an Error object that provides error information if the operation failed. |
+ * Access an Error object that provides error information if the operation failed. |
*
*
* AsyncResult.asyncContext |
- * Define an item of any type that's returned in the AsyncResult object without being altered. |
+ * Define an item of any type that's returned in the AsyncResult object without being altered. |
*
*
*
@@ -8249,17 +8249,17 @@ declare namespace Office {
/**
* Sets or creates the specified setting.
*
- * **Important**: Be aware that the Settings.set method affects only the in-memory copy of the settings property bag.
+ * **Important**: Be aware that the `Settings.set` method affects only the in-memory copy of the settings property bag.
* To make sure that additions or changes to settings will be available to your add-in the next time the document is opened, at some point
- * after calling the Settings.set method and before the add-in is closed, you must call the Settings.saveAsync method to persist settings in
+ * after calling the `Settings.set` method and before the add-in is closed, you must call the `Settings.saveAsync` method to persist settings in
* the document.
*
* @remarks
*
* **Requirement set**: {@link https://learn.microsoft.com/javascript/api/requirement-sets/common/office-add-in-requirement-sets#settings | Settings}
*
- * The set method creates a new setting of the specified name if it does not already exist, or sets an existing setting of the specified name
- * in the in-memory copy of the settings property bag. After you call the Settings.saveAsync method, the value is stored in the document as
+ * The `set` method creates a new setting of the specified name if it does not already exist, or sets an existing setting of the specified name
+ * in the in-memory copy of the settings property bag. After you call the `Settings.saveAsync` method, the value is stored in the document as
* the serialized JSON representation of its data type.
*
* @param settingName The case-sensitive name of the setting to set or create.
diff --git a/types/office-js/index.d.ts b/types/office-js/index.d.ts
index 4f7cfc04f61030..7cbc5d9e0e8808 100644
--- a/types/office-js/index.d.ts
+++ b/types/office-js/index.d.ts
@@ -7911,24 +7911,24 @@ declare namespace Office {
*
* The name of a setting is a string, while the value can be a string, number, boolean, null, object, or array.
*
- * The Settings object is automatically loaded as part of the Document object, and is available by calling the settings property of that object
+ * The Settings object is automatically loaded as part of the `Document` object, and is available by calling the settings property of that object
* when the add-in is activated.
*
- * The developer is responsible for calling the saveAsync method after adding or deleting settings to save the settings in the document.
+ * The developer is responsible for calling the `saveAsync` method after adding or deleting settings to save the settings in the document.
*/
interface Settings {
/**
- * Adds an event handler for the settingsChanged event.
+ * Adds an event handler for the `settingsChanged` event.
*
- * **Important**: Your add-in's code can register a handler for the settingsChanged event when the add-in is running with any Excel client, but
+ * **Important**: Your add-in's code can register a handler for the `settingsChanged` event when the add-in is running with any Excel client, but
* the event will fire only when the add-in is loaded with a spreadsheet that is opened in Excel on the web, and more than one user is editing the
- * spreadsheet (coauthoring). Therefore, effectively the settingsChanged event is supported only in Excel on the web in coauthoring scenarios.
+ * spreadsheet (coauthoring). Therefore, effectively the `settingsChanged` event is supported only in Excel on the web in coauthoring scenarios.
*
* @remarks
*
* **Requirement set**: {@link https://learn.microsoft.com/javascript/api/requirement-sets/common/office-add-in-requirement-sets#methods-that-arent-part-of-a-requirement-set | Not in a set}
*
- * You can add multiple event handlers for the specified eventType as long as the name of each event handler function is unique.
+ * You can add multiple event handlers for the specified `eventType` as long as the name of each event handler function is unique.
*
* @param eventType Specifies the type of event to add. Required.
* @param handler The event handler function to add, whose only parameter is of type {@link Office.SettingsChangedEventArgs}. Required.
@@ -7950,27 +7950,27 @@ declare namespace Office {
*
*
* AsyncResult.error |
- * Access an Error object that provides error information if the operation failed. |
+ * Access an Error object that provides error information if the operation failed. |
*
*
* AsyncResult.asyncContext |
- * Define an item of any type that's returned in the AsyncResult object without being altered. |
+ * Define an item of any type that's returned in the AsyncResult object without being altered. |
*
*
*/
addHandlerAsync(eventType: Office.EventType, handler: any, options?: Office.AsyncContextOptions, callback?: (result: AsyncResult) => void): void;
/**
- * Adds an event handler for the settingsChanged event.
+ * Adds an event handler for the `settingsChanged` event.
*
- * **Important**: Your add-in's code can register a handler for the settingsChanged event when the add-in is running with any Excel client, but
+ * **Important**: Your add-in's code can register a handler for the `settingsChanged` event when the add-in is running with any Excel client, but
* the event will fire only when the add-in is loaded with a spreadsheet that is opened in Excel on the web, and more than one user is editing the
- * spreadsheet (coauthoring). Therefore, effectively the settingsChanged event is supported only in Excel on the web in coauthoring scenarios.
+ * spreadsheet (coauthoring). Therefore, effectively the `settingsChanged` event is supported only in Excel on the web in coauthoring scenarios.
*
* @remarks
*
* **Requirement set**: {@link https://learn.microsoft.com/javascript/api/requirement-sets/common/office-add-in-requirement-sets#methods-that-arent-part-of-a-requirement-set | Not in a set}
*
- * You can add multiple event handlers for the specified eventType as long as the name of each event handler function is unique.
+ * You can add multiple event handlers for the specified `eventType` as long as the name of each event handler function is unique.
*
* @param eventType Specifies the type of event to add. Required.
* @param handler The event handler function to add, whose only parameter is of type {@link Office.SettingsChangedEventArgs}. Required.
@@ -7991,11 +7991,11 @@ declare namespace Office {
*
*
* AsyncResult.error |
- * Access an Error object that provides error information if the operation failed. |
+ * Access an Error object that provides error information if the operation failed. |
*
*
* AsyncResult.asyncContext |
- * Define an item of any type that's returned in the AsyncResult object without being altered. |
+ * Define an item of any type that's returned in the AsyncResult object without being altered. |
*
*
*/
@@ -8021,10 +8021,10 @@ declare namespace Office {
* This method is useful in Excel, Word, and PowerPoint coauthoring scenarios when multiple instances of the same add-in are working against
* the same document. Because each add-in is working against an in-memory copy of the settings loaded from the document at the time the user
* opened it, the settings values used by each user can get out of sync. This can happen whenever an instance of the add-in calls the
- * Settings.saveAsync method to persist all of that user's settings to the document. Calling the refreshAsync method from the event handler
- * for the settingsChanged event of the add-in will refresh the settings values for all users.
+ * `Settings.saveAsync` method to persist all of that user's settings to the document. Calling the `refreshAsync` method from the event handler
+ * for the `settingsChanged` event of the add-in will refresh the settings values for all users.
*
- * In the callback function passed to the refreshAsync method, you can use the properties of the AsyncResult object to return the following
+ * In the callback function passed to the `refreshAsync` method, you can use the properties of the `AsyncResult` object to return the following
* information.
*
*
@@ -8034,7 +8034,7 @@ declare namespace Office {
*
*
* AsyncResult.value |
- * Access a Settings object with the refreshed values. |
+ * Access a Settings object with the refreshed values. |
*
*
* AsyncResult.status |
@@ -8042,11 +8042,11 @@ declare namespace Office {
*
*
* AsyncResult.error |
- * Access an Error object that provides error information if the operation failed. |
+ * Access an Error object that provides error information if the operation failed. |
*
*
* AsyncResult.asyncContext |
- * Define an item of any type that's returned in the AsyncResult object without being altered. |
+ * Define an item of any type that's returned in the AsyncResult object without being altered. |
*
*
*
@@ -8057,33 +8057,33 @@ declare namespace Office {
/**
* Removes the specified setting.
*
- * **Important**: Be aware that the Settings.remove method affects only the in-memory copy of the settings property bag. To persist the removal of
- * the specified setting in the document, at some point after calling the Settings.remove method and before the add-in is closed, you must
- * call the Settings.saveAsync method.
+ * **Important**: Be aware that the `Settings.remove` method affects only the in-memory copy of the settings property bag. To persist the removal of
+ * the specified setting in the document, at some point after calling the `Settings.remove` method and before the add-in is closed, you must
+ * call the `Settings.saveAsync` method.
*
* @remarks
*
* **Requirement set**: {@link https://learn.microsoft.com/javascript/api/requirement-sets/common/office-add-in-requirement-sets#settings | Settings}
*
- * null is a valid value for a setting. Therefore, assigning null to the setting will not remove it from the settings property bag.
+ * `null` is a valid value for a setting. Therefore, assigning `null` to the setting will not remove it from the settings property bag.
*
* @param settingName The case-sensitive name of the setting to remove.
*/
remove(name: string): void;
/**
- * Removes an event handler for the settingsChanged event.
+ * Removes an event handler for the `settingsChanged` event.
*
* @remarks
*
* **Requirement set**: {@link https://learn.microsoft.com/javascript/api/requirement-sets/common/office-add-in-requirement-sets#methods-that-arent-part-of-a-requirement-set | Not in a set}
*
- * If the optional handler parameter is omitted when calling the removeHandlerAsync method, all event handlers for the specified eventType
+ * If the optional handler parameter is omitted when calling the `removeHandlerAsync` method, all event handlers for the specified `eventType`
* will be removed.
*
- * When the function you passed to the callback parameter executes, it receives an AsyncResult object that you can access from the callback
+ * When the function you passed to the callback parameter executes, it receives an `AsyncResult` object that you can access from the callback
* function's only parameter.
*
- * In the callback function passed to the removeHandlerAsync method, you can use the properties of the AsyncResult object to return the
+ * In the callback function passed to the `removeHandlerAsync` method, you can use the properties of the `AsyncResult` object to return the
* following information.
*
*
@@ -8101,11 +8101,11 @@ declare namespace Office {
*
*
* AsyncResult.error |
- * Access an Error object that provides error information if the operation failed. |
+ * Access an Error object that provides error information if the operation failed. |
*
*
* AsyncResult.asyncContext |
- * Define an item of any type that's returned in the AsyncResult object without being altered. |
+ * Define an item of any type that's returned in the AsyncResult object without being altered. |
*
*
*
@@ -8115,19 +8115,19 @@ declare namespace Office {
*/
removeHandlerAsync(eventType: Office.EventType, options?: RemoveHandlerOptions, callback?: (result: AsyncResult) => void): void;
/**
- * Removes an event handler for the settingsChanged event.
+ * Removes an event handler for the `settingsChanged` event.
*
* @remarks
*
* **Requirement set**: {@link https://learn.microsoft.com/javascript/api/requirement-sets/common/office-add-in-requirement-sets#methods-that-arent-part-of-a-requirement-set | Not in a set}
*
- * If the optional handler parameter is omitted when calling the removeHandlerAsync method, all event handlers for the specified eventType
+ * If the optional handler parameter is omitted when calling the `removeHandlerAsync` method, all event handlers for the specified `eventType`
* will be removed.
*
- * When the function you passed to the callback parameter executes, it receives an AsyncResult object that you can access from the callback
+ * When the function you passed to the callback parameter executes, it receives an `AsyncResult` object that you can access from the callback
* function's only parameter.
*
- * In the callback function passed to the removeHandlerAsync method, you can use the properties of the AsyncResult object to return the
+ * In the callback function passed to the `removeHandlerAsync` method, you can use the properties of the `AsyncResult` object to return the
* following information.
*
*
@@ -8145,11 +8145,11 @@ declare namespace Office {
*
*
* AsyncResult.error |
- * Access an Error object that provides error information if the operation failed. |
+ * Access an Error object that provides error information if the operation failed. |
*
*
* AsyncResult.asyncContext |
- * Define an item of any type that's returned in the AsyncResult object without being altered. |
+ * Define an item of any type that's returned in the AsyncResult object without being altered. |
*
*
*
@@ -8165,11 +8165,11 @@ declare namespace Office {
* **Requirement set**: {@link https://learn.microsoft.com/javascript/api/requirement-sets/common/office-add-in-requirement-sets#settings | Settings}
*
* Any settings previously saved by an add-in are loaded when it is initialized, so during the lifetime of the session you can just use the
- * set and get methods to work with the in-memory copy of the settings property bag. When you want to persist the settings so that they are
- * available the next time the add-in is used, use the saveAsync method.
+ * `set` and `get` methods to work with the in-memory copy of the settings property bag. When you want to persist the settings so that they are
+ * available the next time the add-in is used, use the `saveAsync` method.
*
- * **Note**: The saveAsync method persists the in-memory settings property bag into the document file. However, the changes to the document file
- * itself are saved only when the user (or AutoRecover setting) saves the document to the file system. The refreshAsync method is only useful
+ * **Note**: The `saveAsync` method persists the in-memory settings property bag into the document file. However, the changes to the document file
+ * itself are saved only when the user (or AutoRecover setting) saves the document to the file system. The `refreshAsync` method is only useful
* in coauthoring scenarios when other instances of the same add-in might change the settings and those changes should be made available to
* all instances.
*
@@ -8188,11 +8188,11 @@ declare namespace Office {
*
*
* AsyncResult.error |
- * Access an Error object that provides error information if the operation failed. |
+ * Access an Error object that provides error information if the operation failed. |
*
*
* AsyncResult.asyncContext |
- * Define an item of any type that's returned in the AsyncResult object without being altered. |
+ * Define an item of any type that's returned in the AsyncResult object without being altered. |
*
*
*
@@ -8208,11 +8208,11 @@ declare namespace Office {
* **Requirement set**: {@link https://learn.microsoft.com/javascript/api/requirement-sets/common/office-add-in-requirement-sets#settings | Settings}
*
* Any settings previously saved by an add-in are loaded when it is initialized, so during the lifetime of the session you can just use the
- * set and get methods to work with the in-memory copy of the settings property bag. When you want to persist the settings so that they are
- * available the next time the add-in is used, use the saveAsync method.
+ * `set` and `get` methods to work with the in-memory copy of the settings property bag. When you want to persist the settings so that they are
+ * available the next time the add-in is used, use the `saveAsync` method.
*
- * **Note**: The saveAsync method persists the in-memory settings property bag into the document file. However, the changes to the document file
- * itself are saved only when the user (or AutoRecover setting) saves the document to the file system. The refreshAsync method is only useful
+ * **Note**: The `saveAsync` method persists the in-memory settings property bag into the document file. However, the changes to the document file
+ * itself are saved only when the user (or AutoRecover setting) saves the document to the file system. The `refreshAsync` method is only useful
* in coauthoring scenarios when other instances of the same add-in might change the settings and those changes should be made available to
* all instances.
*
@@ -8231,11 +8231,11 @@ declare namespace Office {
*
*
* AsyncResult.error |
- * Access an Error object that provides error information if the operation failed. |
+ * Access an Error object that provides error information if the operation failed. |
*
*
* AsyncResult.asyncContext |
- * Define an item of any type that's returned in the AsyncResult object without being altered. |
+ * Define an item of any type that's returned in the AsyncResult object without being altered. |
*
*
*
@@ -8245,17 +8245,17 @@ declare namespace Office {
/**
* Sets or creates the specified setting.
*
- * **Important**: Be aware that the Settings.set method affects only the in-memory copy of the settings property bag.
+ * **Important**: Be aware that the `Settings.set` method affects only the in-memory copy of the settings property bag.
* To make sure that additions or changes to settings will be available to your add-in the next time the document is opened, at some point
- * after calling the Settings.set method and before the add-in is closed, you must call the Settings.saveAsync method to persist settings in
+ * after calling the `Settings.set` method and before the add-in is closed, you must call the `Settings.saveAsync` method to persist settings in
* the document.
*
* @remarks
*
* **Requirement set**: {@link https://learn.microsoft.com/javascript/api/requirement-sets/common/office-add-in-requirement-sets#settings | Settings}
*
- * The set method creates a new setting of the specified name if it does not already exist, or sets an existing setting of the specified name
- * in the in-memory copy of the settings property bag. After you call the Settings.saveAsync method, the value is stored in the document as
+ * The `set` method creates a new setting of the specified name if it does not already exist, or sets an existing setting of the specified name
+ * in the in-memory copy of the settings property bag. After you call the `Settings.saveAsync` method, the value is stored in the document as
* the serialized JSON representation of its data type.
*
* @param settingName The case-sensitive name of the setting to set or create.