@@ -14,7 +14,6 @@ export class IOSDeviceLiveSyncService extends DeviceLiveSyncServiceBase implemen
14
14
private $iOSEmulatorServices : Mobile . IiOSSimulatorService ,
15
15
private $iOSDebuggerPortService : IIOSDebuggerPortService ,
16
16
private $logger : ILogger ,
17
- private $fs : IFileSystem ,
18
17
private $processService : IProcessService ,
19
18
protected $platformsData : IPlatformsData ,
20
19
protected device : Mobile . IiOSDevice ) {
@@ -71,8 +70,7 @@ export class IOSDeviceLiveSyncService extends DeviceLiveSyncServiceBase implemen
71
70
}
72
71
73
72
if ( await this . setupSocketIfNeeded ( projectData ) ) {
74
- await this . liveEdit ( scriptFiles ) ;
75
- await this . reloadPage ( deviceAppData , otherFiles ) ;
73
+ await this . reloadPage ( otherFiles ) ;
76
74
} else {
77
75
await this . restartApplication ( deviceAppData , projectData . projectName ) ;
78
76
}
@@ -82,7 +80,7 @@ export class IOSDeviceLiveSyncService extends DeviceLiveSyncServiceBase implemen
82
80
return this . device . applicationManager . restartApplication ( { appId : deviceAppData . appIdentifier , projectName } ) ;
83
81
}
84
82
85
- private async reloadPage ( deviceAppData : Mobile . IDeviceAppData , localToDevicePaths : Mobile . ILocalToDevicePathData [ ] ) : Promise < void > {
83
+ private async reloadPage ( localToDevicePaths : Mobile . ILocalToDevicePathData [ ] ) : Promise < void > {
86
84
if ( localToDevicePaths . length ) {
87
85
const message = JSON . stringify ( {
88
86
method : "Page.reload" ,
@@ -96,22 +94,6 @@ export class IOSDeviceLiveSyncService extends DeviceLiveSyncServiceBase implemen
96
94
}
97
95
}
98
96
99
- private async liveEdit ( localToDevicePaths : Mobile . ILocalToDevicePathData [ ] ) : Promise < void > {
100
- for ( const localToDevicePath of localToDevicePaths ) {
101
- const content = this . $fs . readText ( localToDevicePath . getLocalPath ( ) ) ;
102
- const message = JSON . stringify ( {
103
- method : "Debugger.setScriptSource" ,
104
- params : {
105
- scriptUrl : localToDevicePath . getRelativeToProjectBasePath ( ) ,
106
- scriptSource : content
107
- } ,
108
- id : ++ currentPageReloadId
109
- } ) ;
110
-
111
- await this . sendMessage ( message ) ;
112
- }
113
- }
114
-
115
97
private attachEventHandlers ( ) : void {
116
98
this . $processService . attachToProcessExitSignals ( this , this . destroySocket ) ;
117
99
0 commit comments