Skip to content

Commit 4c45dbc

Browse files
committed
Prep for 0.7.0.
1 parent 6c26065 commit 4c45dbc

File tree

5 files changed

+46
-29
lines changed

5 files changed

+46
-29
lines changed

CHANGES.md

Lines changed: 25 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,49 +1,50 @@
1-
### NEXT
1+
### July 15, 2016 - 0.7.0
22

3-
* `NEW` adds an example to the dispatch modal - thx [@darinwilson](https://github.com/darinwilson)
3+
* `NEW` android ip auto-detection support! - [@jhen0409](https://github.com/jhen0409)
4+
* `NEW` adds an example to the dispatch modal - [@darinwilson](https://github.com/darinwilson)
5+
* `NEW` updates the React DOM example to this century - [@skellock](https://github.com/skellock)
46

57
### April 27, 2016 - 0.6.1
68

7-
* `FIX` adds compatibility with Node 4.x and npm 2.x - thx [@skellock](https://github.com/skellock) - found by [@maraujop](https://github.com/maraujop) and [@avioli](https://github.com/avioli)
8-
* `MOD` no longer using `fbjs` for `performanceNow()` - thx [@skellock](https://github.com/skellock) - found by [@avioli](https://github.com/avioli)
9+
* `FIX` adds compatibility with Node 4.x and npm 2.x - [@skellock](https://github.com/skellock) - found by [@maraujop](https://github.com/maraujop) and [@avioli](https://github.com/avioli)
10+
* `MOD` no longer using `fbjs` for `performanceNow()` - [@skellock](https://github.com/skellock) - found by [@avioli](https://github.com/avioli)
911

1012
### April 24, 2016 - 0.6.0
1113

12-
* `NEW` adds a way to do benchmarks - thx [@skellock](https://github.com/skellock)
13-
* `NEW` press `c` to see connected clients - thx [@andrewvy](https://github.com/andrewvy)
14+
* `NEW` adds a way to do benchmarks - [@skellock](https://github.com/skellock)
15+
* `NEW` press `c` to see connected clients - [@andrewvy](https://github.com/andrewvy)
1416

1517
### April 23, 2016 - 0.5.0
1618

17-
* `NEW` additional details about the client are now shown when connecting - thx [@andrewvy](https://github.com/andrewvy)
18-
* `NEW` client count is shown in status bar - thx [@andrewvy](https://github.com/andrewvy)
19-
* `NEW` a simpler way to integrate redux with an enhancer - thx [@andrewvy](https://github.com/andrewvy)
20-
* `FIX` adds a .babelrc to the react native example app - thx [@skellock](https://github.com/skellock)
21-
* `FIX` the redux action timer is showing the correct times again - thx [@skellock](https://github.com/skellock)
22-
* `MOD` adds a working Android example app - thx [@skellock](https://github.com/skellock)
23-
* `DOC` made a note about ensuring `connect()` gets triggered first in your app - thx [@skellock](https://github.com/skellock)
19+
* `NEW` additional details about the client are now shown when connecting - [@andrewvy](https://github.com/andrewvy)
20+
* `NEW` client count is shown in status bar - [@andrewvy](https://github.com/andrewvy)
21+
* `NEW` a simpler way to integrate redux with an enhancer - [@andrewvy](https://github.com/andrewvy)
22+
* `FIX` adds a .babelrc to the react native example app - [@skellock](https://github.com/skellock)
23+
* `FIX` the redux action timer is showing the correct times again - [@skellock](https://github.com/skellock)
24+
* `MOD` adds a working Android example app - [@skellock](https://github.com/skellock)
25+
* `DOC` made a note about ensuring `connect()` gets triggered first in your app - [@skellock](https://github.com/skellock)
2426

2527
### April 23, 2016 - 0.4.0
2628

27-
* `NEW` a way to configure options on the client - thx [@gantman](https://github.com/gantman)
28-
* `NEW` a master switch to turn off everything in 1 spot - thx [@gantman](https://github.com/gantman)
29-
* `FIX` fixed the optional user agent assignment issues - thx [@skellock](https://github.com/skellock)
29+
* `NEW` a way to configure options on the client - [@gantman](https://github.com/gantman)
30+
* `NEW` a master switch to turn off everything in 1 spot - [@gantman](https://github.com/gantman)
31+
* `FIX` fixed the optional user agent assignment issues - [@skellock](https://github.com/skellock)
3032

3133
### April 22, 2016 - 0.3.0
3234

33-
* `NEW` a help menu to show key commands - thx [@gantman](https://github.com/gantman)
34-
* `NEW` emoji logging 🎉 - thx [@skellock](https://github.com/skellock)
35+
* `NEW` a help menu to show key commands - [@gantman](https://github.com/gantman)
36+
* `NEW` emoji logging 🎉 - [@skellock](https://github.com/skellock)
3537
* `NEW` the client is now transpiled for easy integration into React DOM - found by [@derekyau](https://github.com/derekyau) and [@Hyra](https://github.com/Hyra)
36-
* `MOD` returns the redux store from `addReduxStore` - thx [@gantman](https://github.com/gantman)
38+
* `MOD` returns the redux store from `addReduxStore` - [@gantman](https://github.com/gantman)
3739
* `FIX` stop clobbering the window.navigator - found by [@kevinvangelder](https://github.com/kevinvangelder)
3840
* `FIX` separated the examples to prevent colliding deps - found by [@gantman](https://github.com/gantman)
39-
* `DOC` README updates - thx [@gantman](https://github.com/gantman) and [@darinwilson](https://github.com/darinwilson)
41+
* `DOC` README updates - [@gantman](https://github.com/gantman) and [@darinwilson](https://github.com/darinwilson)
4042

4143
### April 21, 2016 - 0.2.0
4244

43-
* `NEW` supports React DOM - thx [@skellock](https://github.com/skellock)
44-
* `NEW` supports React Native Web - thx [@necolas](https://github.com/necolas)
45+
* `NEW` supports React DOM - [@skellock](https://github.com/skellock)
46+
* `NEW` supports React Native Web - [@necolas](https://github.com/necolas)
4547

4648
### April 20, 2016 - 0.1.0
4749

48-
* `NEW` initial release - thx [@skellock](https://github.com/skellock)
49-
50+
* `NEW` initial release - [@skellock](https://github.com/skellock)

README.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -279,4 +279,3 @@ be cool? A REPL. We should do that."
279279
# Change Log
280280

281281
See the full [CHANGES.md](CHANGES.md) file.
282-

bin/reactotron.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -340,7 +340,7 @@ var COMMAND$7 = 'redux.dispatch.prompt';
340340
Prompts for a path to grab some redux keys from.
341341
*/
342342
var process$8 = function process$8(context, action) {
343-
context.prompt('Action to dispatch', function (value) {
343+
context.prompt('Action to dispatch (e.g. {type: \'MY_ACTION\'})', function (value) {
344344
var action = null;
345345

346346
// try not to blow up the frame

dist/client.js

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ var _extends = Object.assign || function (target) { for (var i = 1; i < argument
44

55
// --- Begin Awkward Hackzorz ---
66

7-
var REACTOTRON_VERSION = '0.6.1';
7+
var REACTOTRON_VERSION = '0.7.0';
88
var R = require('ramda');
99

1010
// client enabled flag
@@ -54,6 +54,21 @@ client.onCommand('devMenu.reload', function (action, client) {
5454
// devMenu && devMenu.reload()
5555
});
5656

57+
/*
58+
* Get React Native server IP if hostname is `localhost`
59+
* On Android emulator, the IP of host is `10.0.2.2` (Genymotion: 10.0.3.2)
60+
*/
61+
function getHost(hostname) {
62+
if ((hostname === 'localhost' || hostname === '127.0.0.1') && typeof window !== 'undefined' && window.__fbBatchedBridge && window.__fbBatchedBridge.RemoteModules && window.__fbBatchedBridge.RemoteModules.AndroidConstants) {
63+
var _window$__fbBatchedBr = window.__fbBatchedBridge.RemoteModules.AndroidConstants.ServerHost;
64+
var ServerHost = _window$__fbBatchedBr === undefined ? hostname : _window$__fbBatchedBr;
65+
66+
return ServerHost.split(':')[0];
67+
}
68+
69+
return hostname;
70+
}
71+
5772
/**
5873
Connect to the server.
5974
@param userConfigurations Client configuration for connecting to Reactotron
@@ -74,7 +89,9 @@ client.connect = function () {
7489
};
7590

7691
// merge user input with defaults
77-
var config = _extends({}, defaults, userConfigurations);
92+
var config = _extends({}, defaults, userConfigurations, {
93+
server: getHost(userConfigurations.server || defaults.server)
94+
});
7895

7996
// keep track for all ops
8097
reactotronEnabled = config.enabled;

dist/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -338,7 +338,7 @@ var COMMAND$7 = 'redux.dispatch.prompt';
338338
Prompts for a path to grab some redux keys from.
339339
*/
340340
var process$8 = function process$8(context, action) {
341-
context.prompt('Action to dispatch', function (value) {
341+
context.prompt('Action to dispatch (e.g. {type: \'MY_ACTION\'})', function (value) {
342342
var action = null;
343343

344344
// try not to blow up the frame

0 commit comments

Comments
 (0)