mirror of
				https://github.com/reduxjs/redux-devtools.git
				synced 2025-10-31 07:57:39 +03:00 
			
		
		
		
	open
This commit is contained in:
		
							parent
							
								
									4fcd1d839c
								
							
						
					
					
						commit
						6a2b2a8c7a
					
				|  | @ -1,8 +1,8 @@ | |||
| var opn = require('opn'); | ||||
| var open = require('open'); | ||||
| var path = require('path'); | ||||
| var spawn = require('cross-spawn'); | ||||
| 
 | ||||
| function open(app, options) { | ||||
| function openApp(app, options) { | ||||
|   if (app === true || app === 'electron') { | ||||
|     try { | ||||
|       var port = options.port ? '--port=' + options.port : ''; | ||||
|  | @ -29,10 +29,10 @@ function open(app, options) { | |||
|     } | ||||
|     return; | ||||
|   } | ||||
|   opn( | ||||
|   open( | ||||
|     'http://localhost:' + options.port + '/', | ||||
|     app !== 'browser' ? { app: app } : undefined | ||||
|   ); | ||||
| } | ||||
| 
 | ||||
| module.exports = open; | ||||
| module.exports = openApp; | ||||
|  | @ -6,7 +6,7 @@ var chalk = require('chalk'); | |||
| var injectServer = require('./injectServer'); | ||||
| var getOptions = require('./../src/options'); | ||||
| var server = require('../index'); | ||||
| var open = require('./open'); | ||||
| var openApp = require('./openApp'); | ||||
| 
 | ||||
| var options = getOptions(argv); | ||||
| 
 | ||||
|  | @ -88,7 +88,7 @@ if (argv.injectserver) { | |||
| server(argv).then(function (r) { | ||||
|   if (argv.open && argv.open !== 'false') { | ||||
|     r.on('ready', function () { | ||||
|       open(argv.open, options); | ||||
|       openApp(argv.open, options); | ||||
|     }); | ||||
|   } | ||||
| }); | ||||
|  |  | |||
|  | @ -47,7 +47,7 @@ | |||
|     "lodash": "^4.17.19", | ||||
|     "minimist": "^1.2.5", | ||||
|     "morgan": "^1.10.0", | ||||
|     "opn": "^5.5.0", | ||||
|     "open": "^7.1.0", | ||||
|     "react": "^16.13.1", | ||||
|     "react-dom": "^16.13.1", | ||||
|     "redux-devtools-core": "^1.0.0-2", | ||||
|  |  | |||
							
								
								
									
										10
									
								
								yarn.lock
									
									
									
									
									
								
							
							
						
						
									
										10
									
								
								yarn.lock
									
									
									
									
									
								
							|  | @ -9440,7 +9440,7 @@ is-wsl@^1.1.0: | |||
|   resolved "https://registry.yarnpkg.com/is-wsl/-/is-wsl-1.1.0.tgz#1f16e4aa22b04d1336b66188a66af3c600c3a66d" | ||||
|   integrity sha1-HxbkqiKwTRM2tmGIpmrzxgDDpm0= | ||||
| 
 | ||||
| is-wsl@^2.2.0: | ||||
| is-wsl@^2.1.1, is-wsl@^2.2.0: | ||||
|   version "2.2.0" | ||||
|   resolved "https://registry.yarnpkg.com/is-wsl/-/is-wsl-2.2.0.tgz#74a4c76e77ca9fd3f932f290c17ea326cd157271" | ||||
|   integrity sha512-fKzAra0rGJUUBwGBgNkHZuToZcn+TtXHpeCgmkMJMMYx1sQDYaCSyjJBSCa2nH1DGm7s3n1oBnohoVTBaN7Lww== | ||||
|  | @ -11938,6 +11938,14 @@ onetime@^5.1.0: | |||
|   dependencies: | ||||
|     mimic-fn "^2.1.0" | ||||
| 
 | ||||
| open@^7.1.0: | ||||
|   version "7.1.0" | ||||
|   resolved "https://registry.yarnpkg.com/open/-/open-7.1.0.tgz#68865f7d3cb238520fa1225a63cf28bcf8368a1c" | ||||
|   integrity sha512-lLPI5KgOwEYCDKXf4np7y1PBEkj7HYIyP2DY8mVDRnx0VIIu6bNrRB0R66TuO7Mack6EnTNLm4uvcl1UoklTpA== | ||||
|   dependencies: | ||||
|     is-docker "^2.0.0" | ||||
|     is-wsl "^2.1.1" | ||||
| 
 | ||||
| opencollective-postinstall@^2.0.2: | ||||
|   version "2.0.3" | ||||
|   resolved "https://registry.yarnpkg.com/opencollective-postinstall/-/opencollective-postinstall-2.0.3.tgz#7a0fff978f6dbfa4d006238fbac98ed4198c3259" | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue
	
	Block a user