Skip to content

Commit

Permalink
chore: move react-native-sse out of polyfills
Browse files Browse the repository at this point in the history
  • Loading branch information
yusinto committed Nov 27, 2023
1 parent c85e0b5 commit 151b29b
Show file tree
Hide file tree
Showing 6 changed files with 3 additions and 3 deletions.
3 changes: 2 additions & 1 deletion packages/sdk/react-native/src/platform.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ import type {
} from '@launchdarkly/js-client-sdk-common';

import { name, version } from '../package.json';
import { btoa, EventSource as RNEventSource, uuidv4 } from './polyfills';
import { btoa, uuidv4 } from './polyfills';
import RNEventSource from './react-native-sse';

class PlatformRequests implements Requests {
createEventSource(url: string, eventSourceInitDict: EventSourceInitDict): EventSource {
Expand Down
3 changes: 1 addition & 2 deletions packages/sdk/react-native/src/polyfills/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import EventTarget from 'event-target-shim';

import btoa from './btoa';
import CustomEvent from './CustomEvent';
import EventSource from './react-native-sse';
import uuidv4 from './uuid';

function setupPolyfill() {
Expand All @@ -11,4 +10,4 @@ function setupPolyfill() {
CustomEvent,
});
}
export { btoa, EventSource, setupPolyfill, uuidv4 };
export { btoa, setupPolyfill, uuidv4 };

0 comments on commit 151b29b

Please sign in to comment.