Skip to content

Commit

Permalink
feat: export tool functions directly
Browse files Browse the repository at this point in the history
  • Loading branch information
dsrkafuu committed Dec 8, 2021
1 parent 42adb16 commit a30b9b1
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 4 deletions.
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,14 @@ After installation, you can import the library:

```js
import OverlayAPI from 'ffxiv-overlay-api';
import { OverlayAPI } from 'ffxiv-overlay-api'; // also works
const overlay = new OverlayAPI();

// use static tool functions directly
OverlayAPI.isCEFSharp();
// import tool functions
import { isCEFSharp } from 'ffxiv-overlay-api';
isCEFSharp();
```

Then you can add bunch of different listeners.
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ffxiv-overlay-api",
"version": "4.1.0",
"version": "4.1.1",
"description": "Build your own modern FFXIV overlay with npm & TypeScript support.",
"keywords": [
"ffxiv",
Expand Down
4 changes: 3 additions & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,12 @@
import OverlayAPI from './overlay';

window.OverlayAPI = OverlayAPI;

export { OverlayAPI };
export default OverlayAPI;

export { default as mergeCombatant } from './modules/mergeCombatant';
export { default as isCEFSharp } from './modules/isCEFSharp';

export type {
JobType,
EncounterData,
Expand Down

0 comments on commit a30b9b1

Please sign in to comment.