Skip to content

Commit

Permalink
implement standard global navigator check for ReactNative
Browse files Browse the repository at this point in the history
  • Loading branch information
amazingwebdev committed Nov 20, 2016
1 parent 592804f commit a741743
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
4 changes: 3 additions & 1 deletion build/lib/fetcher.js

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

2 changes: 1 addition & 1 deletion build/lib/fetcher.js.map

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

5 changes: 3 additions & 2 deletions src/lib/fetcher.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,9 @@ import { RequestOptions } from './requestOptions';
import * as querystring from 'querystring';
import events = require('events');
import urlJoin = require('url-join');

import fetch = require('isomorphic-fetch');
if (navigator.product !== 'ReactNative') {
const fetch = require('isomorphic-fetch');
}
import Promise = require('bluebird');

interface FetcherRequest {
Expand Down

0 comments on commit a741743

Please sign in to comment.