Skip to content

Commit 357e963

Browse files
committed
Support new activeDocument API
1 parent aec975c commit 357e963

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

reference/application.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ The `application` module exposes APIs for exporting content, initiating edits fr
1010
* [.version](#module_application-version) : <code>string</code>
1111
* [.appLanguage](#module_application-appLanguage) : <code>string</code>
1212
* [.systemLocale](#module_application-systemLocale) : <code>string</code>
13+
* [.activeDocument](#module_application-activeDocument) : <code>string</code>
1314

1415

1516
---
@@ -177,3 +178,23 @@ language _and_ region (e.g. "fr_CA" or "en_US").
177178
```js
178179
console.log("OS locale:", application.systemLocale); // e.g. "en_US"
179180
```
181+
182+
183+
---
184+
185+
<a name="module_application-activeDocument"></a>
186+
187+
### *application.activeDocument : <code>string</code>*
188+
189+
Represents the active document. Provides the document guid and current saved name.
190+
191+
**Kind**: static property of [<code>application</code>](#module_application)
192+
**Read only**: true
193+
194+
**Example**
195+
```js
196+
var application = require("application");
197+
let documentInfo = application.activeDocument;
198+
console.log(“Document title:+ documentInfo.name);
199+
console.log(“Document unique Id:+ documentInfo.guid);
200+
```

0 commit comments

Comments
 (0)