# io.Connect Office

**Kind**: module | **Library**: @interopio/office

**Source**: https://docs.interop.io/adapters/reference/javascript/io.connect office/index.html

The `@interopio/office` library allows your web apps to interoperate with Microsoft Office apps like Outlook, Word, and Excel.

## Library Usage

The `@interopio/office` library is available as an NPM package and is also distributed as JavaScript files with io.Connect Desktop.

To install the `@interopio/office` library, execute the following command:

```cmd
npm install@interopio/office
```

You can now import the factory function exposed by the library:

```javascript
import IOConnectOffice from "@interopio/office";
```

You can also reference the library as a JavaScript file in the HTML file of your web app by using a `<script>` tag:

```html
<script type="module" src="./office.min.js"></script>
```

## Initialization

The `@interopio/office` library exposes a global factory function called `IOConnectOffice()` which you must invoke to initialize the library in your app.
The factory function accepts an optional `Config` object which you can use to configure various features of the library.

```javascript
import IOConnectOffice from "@interopio/office";

// Optional configuration for the library.
const config = {
// Disabling the Excel and Word APIs.
excel: false,
word: false
};

// Initializing the library and obtaining a reference to the API object.
const office = await IOConnectOffice(config);
```

## Interfaces

- [API](https://docs.interop.io/adapters/reference/javascript/io.connect%20office/api/index.md): The initialized API object as returned by the `IOConnectOffice()` factory function.
- [Config](https://docs.interop.io/adapters/reference/javascript/io.connect%20office/config/index.md): Object for configuring the initialization of the `@interopio/office` library.

## Functions

- [IOConnectOffice](https://docs.interop.io/adapters/reference/javascript/io.connect%20office/ioconnectoffice/index.md): Factory function for initializing the `@interopio/office` library.
