Skip to content

Commit

Permalink
Merge pull request #772 from nextcloud-libraries/fix/do-not-pollute-g…
Browse files Browse the repository at this point in the history
…lobal-declarations

fix: Do not include declarations for private globals in distribution
  • Loading branch information
susnux authored May 27, 2024
2 parents 25f1b59 + 752e1c4 commit 74c2fef
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
9 changes: 9 additions & 0 deletions lib/globals.d.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,14 @@
import type { EventBus } from './EventBus.ts'

declare global {
const __pkg_version: string

interface Window {
OC: {
_eventBus?: EventBus
}
_nc_event_bus?: EventBus
}
}

export {}
9 changes: 0 additions & 9 deletions lib/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,6 @@ export type { Event, NextcloudEvents } from './Event'
export { ProxyBus } from './ProxyBus'
export { SimpleBus } from './SimpleBus'

declare global {
interface Window {
OC: {
_eventBus?: EventBus
}
_nc_event_bus?: EventBus
}
}

let bus: EventBus | null = null

/**
Expand Down

0 comments on commit 74c2fef

Please sign in to comment.