Adding packages

Removing unsupported node.js parts
master
Jonas Franz 8 years ago committed by Gitea
parent 48ebea88f1
commit 8be0eb57ce
  1. 10
      ApiClient.js
  2. 13
      package.json

@ -161,16 +161,6 @@ export default class ApiClient {
* @returns {Boolean} <code>true</code> if <code>param</code> represents a file.
*/
isFileParam(param) {
// fs.ReadStream in Node.js and Electron (but not in runtime like browserify)
if (typeof require === 'function') {
let fs;
try {
fs = require('fs');
} catch (err) {}
if (fs && fs.ReadStream && param instanceof fs.ReadStream) {
return true;
}
}
// Buffer in Node.js
if (typeof Buffer === 'function' && param instanceof Buffer) {

@ -3,9 +3,15 @@
"version": "0.1.0",
"private": true,
"devDependencies": {
"babel-core": "6.18.0",
"babel-preset-es2015": "^6.24.1",
"babel-preset-stage-0": "^6.24.1",
"expect.js": "~0.3.1",
"jest-expo": "~19.0.0",
"mocha": "~2.3.4",
"react-native-scripts": "1.1.0",
"react-test-renderer": "16.0.0-alpha.12"
"react-test-renderer": "16.0.0-alpha.12",
"sinon": "1.17.3"
},
"main": "./node_modules/react-native-scripts/build/bin/crna-entry.js",
"scripts": {
@ -21,10 +27,13 @@
"dependencies": {
"@expo/vector-icons": "^5.0.0",
"@exponent/vector-icons": "^4.0.0",
"babel": "^6.23.0",
"babel-cli": "^6.24.1",
"expo": "^19.0.0",
"native-base": "^2.3.1",
"react": "16.0.0-alpha.12",
"react-native": "^0.46.1",
"react-navigation": "^1.0.0-beta.11"
"react-navigation": "^1.0.0-beta.11",
"superagent": "3.5.2"
}
}

Loading…
Cancel
Save