@appzung/react-native-code-push 10.0.1 → 10.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -3
- package/android/app/src/main/java/com/appzung/codepush/react/CodePush.java +3 -0
- package/android/app/src/main/java/com/appzung/codepush/react/CodePushNativeModule.java +14 -0
- package/ios/CodePush/CodePush.h +1 -0
- package/ios/CodePush/CodePush.m +64 -13
- package/ios/CodePush/CodePushConfig.m +4 -0
- package/lib/commonjs/CodePush.js +6 -2
- package/lib/commonjs/CodePush.js.map +1 -1
- package/lib/commonjs/allowRestart.js +2 -0
- package/lib/commonjs/allowRestart.js.map +1 -1
- package/lib/commonjs/checkForUpdates.js +23 -25
- package/lib/commonjs/checkForUpdates.js.map +1 -1
- package/lib/commonjs/clearUpdates.js +2 -1
- package/lib/commonjs/clearUpdates.js.map +1 -1
- package/lib/commonjs/disallowRestart.js +2 -0
- package/lib/commonjs/disallowRestart.js.map +1 -1
- package/lib/commonjs/enums/CheckFrequency.enum.js +2 -2
- package/lib/commonjs/enums/InstallMode.enum.js +7 -3
- package/lib/commonjs/enums/InstallMode.enum.js.map +1 -1
- package/lib/commonjs/enums/SyncStatus.enum.js +7 -7
- package/lib/commonjs/enums/UpdateState.enum.js +7 -6
- package/lib/commonjs/enums/UpdateState.enum.js.map +1 -1
- package/lib/commonjs/getClientUniqueId.js +16 -0
- package/lib/commonjs/getClientUniqueId.js.map +1 -0
- package/lib/commonjs/index.js +34 -13
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/internals/CodePushApiSdk.errors.js +26 -0
- package/lib/commonjs/internals/CodePushApiSdk.errors.js.map +1 -0
- package/lib/commonjs/internals/CodePushApiSdk.js +100 -0
- package/lib/commonjs/internals/CodePushApiSdk.js.map +1 -0
- package/lib/commonjs/{enums/DeploymentStatus.enum.js → internals/CodePushApiSdk.types.js} +3 -2
- package/lib/commonjs/internals/CodePushApiSdk.types.js.map +1 -0
- package/lib/commonjs/internals/RemotePackageImplementation.js +6 -5
- package/lib/commonjs/internals/RemotePackageImplementation.js.map +1 -1
- package/lib/commonjs/internals/getConfiguration.js +4 -0
- package/lib/commonjs/internals/getConfiguration.js.map +1 -1
- package/lib/commonjs/internals/utils/fetchRetry.js +59 -0
- package/lib/commonjs/internals/utils/fetchRetry.js.map +1 -0
- package/lib/commonjs/internals/utils/queryStringify.js +25 -0
- package/lib/commonjs/internals/utils/queryStringify.js.map +1 -0
- package/lib/commonjs/internals/utils/requestFetchAdapter.js +33 -0
- package/lib/commonjs/internals/utils/requestFetchAdapter.js.map +1 -0
- package/lib/commonjs/internals/version.js +1 -1
- package/lib/commonjs/notifyAppReady.js +11 -9
- package/lib/commonjs/notifyAppReady.js.map +1 -1
- package/lib/commonjs/resetClientUniqueId.js +18 -0
- package/lib/commonjs/resetClientUniqueId.js.map +1 -0
- package/lib/commonjs/restartApp.js +2 -0
- package/lib/commonjs/restartApp.js.map +1 -1
- package/lib/commonjs/sync.js +5 -3
- package/lib/commonjs/sync.js.map +1 -1
- package/lib/module/CodePush.js +6 -2
- package/lib/module/CodePush.js.map +1 -1
- package/lib/module/allowRestart.js +2 -0
- package/lib/module/allowRestart.js.map +1 -1
- package/lib/module/checkForUpdates.js +23 -25
- package/lib/module/checkForUpdates.js.map +1 -1
- package/lib/module/clearUpdates.js +2 -1
- package/lib/module/clearUpdates.js.map +1 -1
- package/lib/module/disallowRestart.js +2 -0
- package/lib/module/disallowRestart.js.map +1 -1
- package/lib/module/enums/CheckFrequency.enum.js +2 -2
- package/lib/module/enums/InstallMode.enum.js +7 -3
- package/lib/module/enums/InstallMode.enum.js.map +1 -1
- package/lib/module/enums/SyncStatus.enum.js +7 -7
- package/lib/module/enums/UpdateState.enum.js +7 -6
- package/lib/module/enums/UpdateState.enum.js.map +1 -1
- package/lib/module/getClientUniqueId.js +12 -0
- package/lib/module/getClientUniqueId.js.map +1 -0
- package/lib/module/index.js +3 -1
- package/lib/module/index.js.map +1 -1
- package/lib/module/internals/CodePushApiSdk.errors.js +20 -0
- package/lib/module/internals/CodePushApiSdk.errors.js.map +1 -0
- package/lib/module/internals/CodePushApiSdk.js +96 -0
- package/lib/module/internals/CodePushApiSdk.js.map +1 -0
- package/lib/module/{enums/DeploymentStatus.enum.js → internals/CodePushApiSdk.types.js} +2 -1
- package/lib/module/internals/CodePushApiSdk.types.js.map +1 -0
- package/lib/module/internals/RemotePackageImplementation.js +6 -5
- package/lib/module/internals/RemotePackageImplementation.js.map +1 -1
- package/lib/module/internals/getConfiguration.js +3 -0
- package/lib/module/internals/getConfiguration.js.map +1 -1
- package/lib/module/internals/utils/fetchRetry.js +55 -0
- package/lib/module/internals/utils/fetchRetry.js.map +1 -0
- package/lib/module/internals/utils/queryStringify.js +21 -0
- package/lib/module/internals/utils/queryStringify.js.map +1 -0
- package/lib/module/internals/utils/requestFetchAdapter.js +29 -0
- package/lib/module/internals/utils/requestFetchAdapter.js.map +1 -0
- package/lib/module/internals/version.js +1 -1
- package/lib/module/notifyAppReady.js +11 -9
- package/lib/module/notifyAppReady.js.map +1 -1
- package/lib/module/resetClientUniqueId.js +14 -0
- package/lib/module/resetClientUniqueId.js.map +1 -0
- package/lib/module/restartApp.js +2 -0
- package/lib/module/restartApp.js.map +1 -1
- package/lib/module/sync.js +5 -3
- package/lib/module/sync.js.map +1 -1
- package/lib/typescript/commonjs/src/CodePush.d.ts +10 -5
- package/lib/typescript/commonjs/src/CodePush.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/allowRestart.d.ts +2 -0
- package/lib/typescript/commonjs/src/allowRestart.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/checkForUpdates.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/clearUpdates.d.ts +2 -1
- package/lib/typescript/commonjs/src/clearUpdates.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/disallowRestart.d.ts +2 -0
- package/lib/typescript/commonjs/src/disallowRestart.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/enums/CheckFrequency.enum.d.ts +2 -2
- package/lib/typescript/commonjs/src/enums/InstallMode.enum.d.ts +7 -3
- package/lib/typescript/commonjs/src/enums/InstallMode.enum.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/enums/SyncStatus.enum.d.ts +7 -7
- package/lib/typescript/commonjs/src/enums/UpdateState.enum.d.ts +7 -6
- package/lib/typescript/commonjs/src/enums/UpdateState.enum.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/getClientUniqueId.d.ts +5 -0
- package/lib/typescript/commonjs/src/getClientUniqueId.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/index.d.ts +3 -1
- package/lib/typescript/commonjs/src/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/internals/CodePushApiSdk.d.ts +13 -0
- package/lib/typescript/commonjs/src/internals/CodePushApiSdk.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/internals/CodePushApiSdk.errors.d.ts +9 -0
- package/lib/typescript/commonjs/src/internals/CodePushApiSdk.errors.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/internals/CodePushApiSdk.types.d.ts +101 -0
- package/lib/typescript/commonjs/src/internals/CodePushApiSdk.types.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/internals/RNAppZungCodePushModuleSpec.d.ts +1 -0
- package/lib/typescript/commonjs/src/internals/RNAppZungCodePushModuleSpec.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/internals/RemotePackageImplementation.d.ts +2 -2
- package/lib/typescript/commonjs/src/internals/RemotePackageImplementation.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/internals/getConfiguration.d.ts +1 -0
- package/lib/typescript/commonjs/src/internals/getConfiguration.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/internals/types.d.ts +2 -2
- package/lib/typescript/commonjs/src/internals/types.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/internals/utils/fetchRetry.d.ts +9 -0
- package/lib/typescript/commonjs/src/internals/utils/fetchRetry.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/internals/utils/queryStringify.d.ts +4 -0
- package/lib/typescript/commonjs/src/internals/utils/queryStringify.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/internals/utils/requestFetchAdapter.d.ts +3 -0
- package/lib/typescript/commonjs/src/internals/utils/requestFetchAdapter.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/internals/version.d.ts +1 -1
- package/lib/typescript/commonjs/src/notifyAppReady.d.ts +2 -0
- package/lib/typescript/commonjs/src/notifyAppReady.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/resetClientUniqueId.d.ts +5 -0
- package/lib/typescript/commonjs/src/resetClientUniqueId.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/restartApp.d.ts +2 -0
- package/lib/typescript/commonjs/src/restartApp.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/sync.d.ts +3 -1
- package/lib/typescript/commonjs/src/sync.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/types.d.ts +72 -29
- package/lib/typescript/commonjs/src/types.d.ts.map +1 -1
- package/lib/typescript/module/src/CodePush.d.ts +10 -5
- package/lib/typescript/module/src/CodePush.d.ts.map +1 -1
- package/lib/typescript/module/src/allowRestart.d.ts +2 -0
- package/lib/typescript/module/src/allowRestart.d.ts.map +1 -1
- package/lib/typescript/module/src/checkForUpdates.d.ts.map +1 -1
- package/lib/typescript/module/src/clearUpdates.d.ts +2 -1
- package/lib/typescript/module/src/clearUpdates.d.ts.map +1 -1
- package/lib/typescript/module/src/disallowRestart.d.ts +2 -0
- package/lib/typescript/module/src/disallowRestart.d.ts.map +1 -1
- package/lib/typescript/module/src/enums/CheckFrequency.enum.d.ts +2 -2
- package/lib/typescript/module/src/enums/InstallMode.enum.d.ts +7 -3
- package/lib/typescript/module/src/enums/InstallMode.enum.d.ts.map +1 -1
- package/lib/typescript/module/src/enums/SyncStatus.enum.d.ts +7 -7
- package/lib/typescript/module/src/enums/UpdateState.enum.d.ts +7 -6
- package/lib/typescript/module/src/enums/UpdateState.enum.d.ts.map +1 -1
- package/lib/typescript/module/src/getClientUniqueId.d.ts +5 -0
- package/lib/typescript/module/src/getClientUniqueId.d.ts.map +1 -0
- package/lib/typescript/module/src/index.d.ts +3 -1
- package/lib/typescript/module/src/index.d.ts.map +1 -1
- package/lib/typescript/module/src/internals/CodePushApiSdk.d.ts +13 -0
- package/lib/typescript/module/src/internals/CodePushApiSdk.d.ts.map +1 -0
- package/lib/typescript/module/src/internals/CodePushApiSdk.errors.d.ts +9 -0
- package/lib/typescript/module/src/internals/CodePushApiSdk.errors.d.ts.map +1 -0
- package/lib/typescript/module/src/internals/CodePushApiSdk.types.d.ts +101 -0
- package/lib/typescript/module/src/internals/CodePushApiSdk.types.d.ts.map +1 -0
- package/lib/typescript/module/src/internals/RNAppZungCodePushModuleSpec.d.ts +1 -0
- package/lib/typescript/module/src/internals/RNAppZungCodePushModuleSpec.d.ts.map +1 -1
- package/lib/typescript/module/src/internals/RemotePackageImplementation.d.ts +2 -2
- package/lib/typescript/module/src/internals/RemotePackageImplementation.d.ts.map +1 -1
- package/lib/typescript/module/src/internals/getConfiguration.d.ts +1 -0
- package/lib/typescript/module/src/internals/getConfiguration.d.ts.map +1 -1
- package/lib/typescript/module/src/internals/types.d.ts +2 -2
- package/lib/typescript/module/src/internals/types.d.ts.map +1 -1
- package/lib/typescript/module/src/internals/utils/fetchRetry.d.ts +9 -0
- package/lib/typescript/module/src/internals/utils/fetchRetry.d.ts.map +1 -0
- package/lib/typescript/module/src/internals/utils/queryStringify.d.ts +4 -0
- package/lib/typescript/module/src/internals/utils/queryStringify.d.ts.map +1 -0
- package/lib/typescript/module/src/internals/utils/requestFetchAdapter.d.ts +3 -0
- package/lib/typescript/module/src/internals/utils/requestFetchAdapter.d.ts.map +1 -0
- package/lib/typescript/module/src/internals/version.d.ts +1 -1
- package/lib/typescript/module/src/notifyAppReady.d.ts +2 -0
- package/lib/typescript/module/src/notifyAppReady.d.ts.map +1 -1
- package/lib/typescript/module/src/resetClientUniqueId.d.ts +5 -0
- package/lib/typescript/module/src/resetClientUniqueId.d.ts.map +1 -0
- package/lib/typescript/module/src/restartApp.d.ts +2 -0
- package/lib/typescript/module/src/restartApp.d.ts.map +1 -1
- package/lib/typescript/module/src/sync.d.ts +3 -1
- package/lib/typescript/module/src/sync.d.ts.map +1 -1
- package/lib/typescript/module/src/types.d.ts +72 -29
- package/lib/typescript/module/src/types.d.ts.map +1 -1
- package/package.json +6 -4
- package/src/CodePush.tsx +12 -5
- package/src/allowRestart.ts +2 -0
- package/src/checkForUpdates.ts +24 -23
- package/src/clearUpdates.ts +2 -1
- package/src/disallowRestart.ts +2 -0
- package/src/enums/CheckFrequency.enum.ts +2 -2
- package/src/enums/InstallMode.enum.ts +7 -3
- package/src/enums/SyncStatus.enum.ts +7 -7
- package/src/enums/UpdateState.enum.ts +7 -6
- package/src/getClientUniqueId.ts +9 -0
- package/src/index.ts +3 -1
- package/src/internals/CodePushApiSdk.errors.ts +22 -0
- package/src/internals/CodePushApiSdk.ts +133 -0
- package/src/internals/CodePushApiSdk.types.ts +115 -0
- package/src/internals/RNAppZungCodePushModuleSpec.ts +1 -0
- package/src/internals/RemotePackageImplementation.ts +8 -7
- package/src/internals/getConfiguration.ts +4 -0
- package/src/internals/types.ts +2 -2
- package/src/internals/utils/fetchRetry.ts +72 -0
- package/src/internals/utils/queryStringify.ts +22 -0
- package/src/internals/utils/requestFetchAdapter.ts +28 -0
- package/src/internals/version.ts +1 -1
- package/src/notifyAppReady.ts +12 -13
- package/src/resetClientUniqueId.ts +11 -0
- package/src/restartApp.ts +2 -0
- package/src/sync.ts +5 -3
- package/src/types.ts +72 -29
- package/typedoc.json +9 -0
- package/docs/advanced-usage.md +0 -56
- package/docs/api-android.md +0 -22
- package/docs/api-ios.md +0 -19
- package/docs/api-js.md +0 -557
- package/docs/code-signing.md +0 -62
- package/docs/migrating-to-v10.md +0 -31
- package/docs/setup-android.md +0 -81
- package/docs/setup-ios.md +0 -108
- package/docs/setup-windows.md +0 -55
- package/lib/commonjs/enums/DeploymentStatus.enum.js.map +0 -1
- package/lib/commonjs/internals/AcquisitionSdk.js +0 -9
- package/lib/commonjs/internals/AcquisitionSdk.js.map +0 -1
- package/lib/commonjs/internals/getPromisifiedSdk.js +0 -49
- package/lib/commonjs/internals/getPromisifiedSdk.js.map +0 -1
- package/lib/commonjs/internals/utils/request-fetch-adapter.js +0 -50
- package/lib/commonjs/internals/utils/request-fetch-adapter.js.map +0 -1
- package/lib/module/enums/DeploymentStatus.enum.js.map +0 -1
- package/lib/module/internals/AcquisitionSdk.js +0 -5
- package/lib/module/internals/AcquisitionSdk.js.map +0 -1
- package/lib/module/internals/getPromisifiedSdk.js +0 -45
- package/lib/module/internals/getPromisifiedSdk.js.map +0 -1
- package/lib/module/internals/utils/request-fetch-adapter.js +0 -46
- package/lib/module/internals/utils/request-fetch-adapter.js.map +0 -1
- package/lib/typescript/commonjs/src/enums/DeploymentStatus.enum.d.ts +0 -14
- package/lib/typescript/commonjs/src/enums/DeploymentStatus.enum.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/internals/AcquisitionSdk.d.ts +0 -3
- package/lib/typescript/commonjs/src/internals/AcquisitionSdk.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/internals/getPromisifiedSdk.d.ts +0 -13
- package/lib/typescript/commonjs/src/internals/getPromisifiedSdk.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/internals/utils/request-fetch-adapter.d.ts +0 -3
- package/lib/typescript/commonjs/src/internals/utils/request-fetch-adapter.d.ts.map +0 -1
- package/lib/typescript/module/src/enums/DeploymentStatus.enum.d.ts +0 -14
- package/lib/typescript/module/src/enums/DeploymentStatus.enum.d.ts.map +0 -1
- package/lib/typescript/module/src/internals/AcquisitionSdk.d.ts +0 -3
- package/lib/typescript/module/src/internals/AcquisitionSdk.d.ts.map +0 -1
- package/lib/typescript/module/src/internals/getPromisifiedSdk.d.ts +0 -13
- package/lib/typescript/module/src/internals/getPromisifiedSdk.d.ts.map +0 -1
- package/lib/typescript/module/src/internals/utils/request-fetch-adapter.d.ts +0 -3
- package/lib/typescript/module/src/internals/utils/request-fetch-adapter.d.ts.map +0 -1
- package/src/enums/DeploymentStatus.enum.ts +0 -14
- package/src/internals/AcquisitionSdk.ts +0 -3
- package/src/internals/getPromisifiedSdk.ts +0 -72
- package/src/internals/utils/request-fetch-adapter.ts +0 -58
package/README.md
CHANGED
|
@@ -142,7 +142,7 @@ If you would like your app to discover updates more quickly, you can also choose
|
|
|
142
142
|
withCodePush({ checkFrequency: CheckFrequency.ON_APP_RESUME })(MyApp);
|
|
143
143
|
```
|
|
144
144
|
|
|
145
|
-
Alternatively, if you want fine-grained control over when the check happens (like a button press or timer interval), eg. in a staging environment, you can call [`CodePush.sync()`](docs/api-js.md
|
|
145
|
+
Alternatively, if you want fine-grained control over when the check happens (like a button press or timer interval), eg. in a staging environment, you can call [`CodePush.sync()`](docs/api-js/functions/sync.md) at any time with your desired `SyncOptions`, and turn off CodePush's automatic checking by specifying a manual `checkFrequency`:
|
|
146
146
|
|
|
147
147
|
```javascript
|
|
148
148
|
import withCodePush, { CheckFrequency, InstallMode } from '@appzung/react-native-code-push';
|
|
@@ -169,7 +169,7 @@ class MyApp extends Component {
|
|
|
169
169
|
export default withCodePush({ checkFrequency: CheckFrequency.MANUAL })(MyApp);
|
|
170
170
|
```
|
|
171
171
|
|
|
172
|
-
If you would like to display an update confirmation dialog (an "active install"), configure when an available update is installed (like force an immediate restart) or customize the update experience in any other way, refer to the [`
|
|
172
|
+
If you would like to display an update confirmation dialog (an "active install"), configure when an available update is installed (like force an immediate restart) or customize the update experience in any other way, refer to the [`withCodePush()`](docs/api-js/functions/withCodePush.md) API reference for information on how to tweak this default behavior.
|
|
173
173
|
|
|
174
174
|
## Releasing updates
|
|
175
175
|
|
|
@@ -252,7 +252,7 @@ This is not necessarily the case for `updateDialog`, since it won't force the us
|
|
|
252
252
|
|
|
253
253
|
## API Reference
|
|
254
254
|
|
|
255
|
-
- [JavaScript API](docs/api-js.md)
|
|
255
|
+
- [JavaScript API](docs/api-js/README.md)
|
|
256
256
|
- [Objective-C API Reference (iOS)](docs/api-ios.md)
|
|
257
257
|
- [Java API Reference (Android)](docs/api-android.md)
|
|
258
258
|
|
|
@@ -85,6 +85,9 @@ public class CodePush implements ReactPackage {
|
|
|
85
85
|
}
|
|
86
86
|
|
|
87
87
|
String serverUrlFromStrings = getCustomPropertyFromStringsIfExist("ServerUrl");
|
|
88
|
+
if (serverUrlFromStrings == null) {
|
|
89
|
+
serverUrlFromStrings = getCustomPropertyFromStringsIfExist("ServerURL");
|
|
90
|
+
}
|
|
88
91
|
if (serverUrlFromStrings != null) {
|
|
89
92
|
CodePushUtils.log("Executing CodePush with a custom server URL.");
|
|
90
93
|
mServerUrl = serverUrlFromStrings;
|
|
@@ -731,6 +731,20 @@ public class CodePushNativeModule extends ReactContextBaseJavaModule {
|
|
|
731
731
|
mCodePush.clearUpdates();
|
|
732
732
|
}
|
|
733
733
|
|
|
734
|
+
@ReactMethod
|
|
735
|
+
public void resetClientUniqueId(Promise promise) {
|
|
736
|
+
try {
|
|
737
|
+
String newClientUniqueId = UUID.randomUUID().toString();
|
|
738
|
+
SharedPreferences preferences = mCodePush.getContext().getSharedPreferences(CodePushConstants.CODE_PUSH_PREFERENCES, 0);
|
|
739
|
+
preferences.edit().putString(CodePushConstants.CLIENT_UNIQUE_ID_KEY, newClientUniqueId).apply();
|
|
740
|
+
mClientUniqueId = newClientUniqueId;
|
|
741
|
+
promise.resolve(mClientUniqueId);
|
|
742
|
+
} catch (Exception e) {
|
|
743
|
+
CodePushUtils.log(e);
|
|
744
|
+
promise.reject(e);
|
|
745
|
+
}
|
|
746
|
+
}
|
|
747
|
+
|
|
734
748
|
@ReactMethod
|
|
735
749
|
public void addListener(String eventName) {
|
|
736
750
|
// Set up any upstream listeners or background tasks as necessary
|
package/ios/CodePush/CodePush.h
CHANGED
|
@@ -101,6 +101,7 @@
|
|
|
101
101
|
@property (readonly) NSString *buildVersion;
|
|
102
102
|
@property (readonly) NSDictionary *configuration;
|
|
103
103
|
@property (copy) NSString *releaseChannelPublicId;
|
|
104
|
+
@property (readonly) NSString *clientUniqueId;
|
|
104
105
|
@property (copy) NSString *serverURL;
|
|
105
106
|
@property (copy) NSString *publicKey;
|
|
106
107
|
|
package/ios/CodePush/CodePush.m
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
#if __has_include(<React/RCTAssert.h>)
|
|
1
2
|
#import <React/RCTAssert.h>
|
|
2
3
|
#import <React/RCTBridgeModule.h>
|
|
3
4
|
#import <React/RCTConvert.h>
|
|
@@ -5,10 +6,18 @@
|
|
|
5
6
|
#import <React/RCTRootView.h>
|
|
6
7
|
#import <React/RCTUtils.h>
|
|
7
8
|
#import <React/RCTReloadCommand.h>
|
|
9
|
+
#else // back compatibility for RN version < 0.40
|
|
10
|
+
#import "RCTAssert.h"
|
|
11
|
+
#import "RCTBridgeModule.h"
|
|
12
|
+
#import "RCTConvert.h"
|
|
13
|
+
#import "RCTEventDispatcher.h"
|
|
14
|
+
#import "RCTRootView.h"
|
|
15
|
+
#import "RCTUtils.h"
|
|
16
|
+
#endif
|
|
8
17
|
|
|
9
18
|
#import "CodePush.h"
|
|
10
19
|
|
|
11
|
-
@interface CodePush () <RCTBridgeModule>
|
|
20
|
+
@interface CodePush () <RCTBridgeModule, RCTFrameUpdateObserver>
|
|
12
21
|
@end
|
|
13
22
|
|
|
14
23
|
@implementation CodePush {
|
|
@@ -21,8 +30,8 @@
|
|
|
21
30
|
|
|
22
31
|
// Used to coordinate the dispatching of download progress events to JS.
|
|
23
32
|
long long _latestExpectedContentLength;
|
|
24
|
-
long long
|
|
25
|
-
|
|
33
|
+
long long _latestReceivedConentLength;
|
|
34
|
+
BOOL _didUpdateProgress;
|
|
26
35
|
|
|
27
36
|
BOOL _allowed;
|
|
28
37
|
BOOL _restartInProgress;
|
|
@@ -246,6 +255,19 @@ static NSString *const LatestRollbackCountKey = @"count";
|
|
|
246
255
|
#pragma mark - Private API methods
|
|
247
256
|
|
|
248
257
|
@synthesize methodQueue = _methodQueue;
|
|
258
|
+
@synthesize pauseCallback = _pauseCallback;
|
|
259
|
+
@synthesize paused = _paused;
|
|
260
|
+
|
|
261
|
+
- (void)setPaused:(BOOL)paused
|
|
262
|
+
{
|
|
263
|
+
if (_paused != paused) {
|
|
264
|
+
_paused = paused;
|
|
265
|
+
if (_pauseCallback) {
|
|
266
|
+
_pauseCallback();
|
|
267
|
+
}
|
|
268
|
+
}
|
|
269
|
+
}
|
|
270
|
+
|
|
249
271
|
/*
|
|
250
272
|
* This method is used to clear updates that are installed
|
|
251
273
|
* under a different app version and hence don't apply anymore,
|
|
@@ -310,7 +332,7 @@ static NSString *const LatestRollbackCountKey = @"count";
|
|
|
310
332
|
@"totalBytes" : [NSNumber
|
|
311
333
|
numberWithLongLong:_latestExpectedContentLength],
|
|
312
334
|
@"receivedBytes" : [NSNumber
|
|
313
|
-
numberWithLongLong:
|
|
335
|
+
numberWithLongLong:_latestReceivedConentLength]
|
|
314
336
|
}];
|
|
315
337
|
}
|
|
316
338
|
|
|
@@ -374,6 +396,7 @@ static NSString *const LatestRollbackCountKey = @"count";
|
|
|
374
396
|
#ifdef DEBUG
|
|
375
397
|
[self clearDebugUpdates];
|
|
376
398
|
#endif
|
|
399
|
+
self.paused = YES;
|
|
377
400
|
NSUserDefaults *preferences = [NSUserDefaults standardUserDefaults];
|
|
378
401
|
NSDictionary *pendingUpdate = [preferences objectForKey:PendingUpdateKey];
|
|
379
402
|
if (pendingUpdate) {
|
|
@@ -695,6 +718,13 @@ RCT_EXPORT_METHOD(downloadUpdate:(NSDictionary*)updatePackage
|
|
|
695
718
|
forKey:BinaryBundleDateKey];
|
|
696
719
|
}
|
|
697
720
|
|
|
721
|
+
if (notifyProgress) {
|
|
722
|
+
// Set up and unpause the frame observer so that it can emit
|
|
723
|
+
// progress events every frame if the progress is updated.
|
|
724
|
+
_didUpdateProgress = NO;
|
|
725
|
+
self.paused = NO;
|
|
726
|
+
}
|
|
727
|
+
|
|
698
728
|
NSString * publicKey = [[CodePushConfig current] publicKey];
|
|
699
729
|
|
|
700
730
|
[CodePushPackage
|
|
@@ -704,18 +734,17 @@ RCT_EXPORT_METHOD(downloadUpdate:(NSDictionary*)updatePackage
|
|
|
704
734
|
operationQueue:_methodQueue
|
|
705
735
|
// The download is progressing forward
|
|
706
736
|
progressCallback:^(long long expectedContentLength, long long receivedContentLength) {
|
|
707
|
-
// Update the download progress
|
|
708
|
-
|
|
709
|
-
|
|
737
|
+
// Update the download progress so that the frame observer can notify the JS side
|
|
738
|
+
_latestExpectedContentLength = expectedContentLength;
|
|
739
|
+
_latestReceivedConentLength = receivedContentLength;
|
|
740
|
+
_didUpdateProgress = YES;
|
|
710
741
|
|
|
742
|
+
// If the download is completed, stop observing frame
|
|
743
|
+
// updates and synchronously send the last event.
|
|
711
744
|
if (expectedContentLength == receivedContentLength) {
|
|
745
|
+
_didUpdateProgress = NO;
|
|
746
|
+
self.paused = YES;
|
|
712
747
|
[self dispatchDownloadProgressEvent];
|
|
713
|
-
} else if (notifyProgress) {
|
|
714
|
-
NSTimeInterval timestamp = [[NSDate date] timeIntervalSince1970];
|
|
715
|
-
if (timestamp - self->_lastProgressEmitTimestamp > 30.0 / 1000.0) {
|
|
716
|
-
self->_lastProgressEmitTimestamp = timestamp;
|
|
717
|
-
[self dispatchDownloadProgressEvent];
|
|
718
|
-
}
|
|
719
748
|
}
|
|
720
749
|
}
|
|
721
750
|
// The download completed
|
|
@@ -734,6 +763,9 @@ RCT_EXPORT_METHOD(downloadUpdate:(NSDictionary*)updatePackage
|
|
|
734
763
|
[self saveFailedUpdate:mutableUpdatePackage];
|
|
735
764
|
}
|
|
736
765
|
|
|
766
|
+
// Stop observing frame updates if the download fails.
|
|
767
|
+
_didUpdateProgress = NO;
|
|
768
|
+
self.paused = YES;
|
|
737
769
|
reject([NSString stringWithFormat: @"%lu", (long)err.code], err.localizedDescription, err);
|
|
738
770
|
}];
|
|
739
771
|
}
|
|
@@ -1010,6 +1042,13 @@ RCT_EXPORT_METHOD(clearUpdates) {
|
|
|
1010
1042
|
[CodePush clearUpdates];
|
|
1011
1043
|
}
|
|
1012
1044
|
|
|
1045
|
+
RCT_EXPORT_METHOD(resetClientUniqueId:(RCTPromiseResolveBlock)resolve
|
|
1046
|
+
rejecter:(RCTPromiseRejectBlock)reject)
|
|
1047
|
+
{
|
|
1048
|
+
CPLog(@"On iOS, resetting client device ID does nothing as it is the iOS IDFV.");
|
|
1049
|
+
resolve([[CodePushConfig current] clientUniqueId]);
|
|
1050
|
+
}
|
|
1051
|
+
|
|
1013
1052
|
#pragma mark - JavaScript-exported module methods (Private)
|
|
1014
1053
|
|
|
1015
1054
|
/*
|
|
@@ -1075,4 +1114,16 @@ RCT_EXPORT_METHOD(saveStatusReportForRetry:(NSDictionary *)statusReport)
|
|
|
1075
1114
|
[CodePushTelemetryManager saveStatusReportForRetry:statusReport];
|
|
1076
1115
|
}
|
|
1077
1116
|
|
|
1117
|
+
#pragma mark - RCTFrameUpdateObserver Methods
|
|
1118
|
+
|
|
1119
|
+
- (void)didUpdateFrame:(RCTFrameUpdate *)update
|
|
1120
|
+
{
|
|
1121
|
+
if (!_didUpdateProgress) {
|
|
1122
|
+
return;
|
|
1123
|
+
}
|
|
1124
|
+
|
|
1125
|
+
[self dispatchDownloadProgressEvent];
|
|
1126
|
+
_didUpdateProgress = NO;
|
|
1127
|
+
}
|
|
1128
|
+
|
|
1078
1129
|
@end
|
|
@@ -35,6 +35,10 @@ static NSString * const PublicKeyKey = @"publicKey";
|
|
|
35
35
|
NSString *buildVersion = [infoDictionary objectForKey:(NSString *)kCFBundleVersionKey];
|
|
36
36
|
NSString *releaseChannelPublicId = [infoDictionary objectForKey:@"CodePushReleaseChannelPublicId"];
|
|
37
37
|
NSString *serverURL = [infoDictionary objectForKey:@"CodePushServerURL"];
|
|
38
|
+
if (!serverURL) {
|
|
39
|
+
serverURL = [infoDictionary objectForKey:@"CodePushServerUrl"];
|
|
40
|
+
}
|
|
41
|
+
|
|
38
42
|
NSString *publicKey = [infoDictionary objectForKey:@"CodePushSigningPublicKey"];
|
|
39
43
|
|
|
40
44
|
NSUserDefaults *userDefaults = [NSUserDefaults standardUserDefaults];
|
package/lib/commonjs/CodePush.js
CHANGED
|
@@ -14,14 +14,18 @@ var _sync = require("./sync.js");
|
|
|
14
14
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
15
15
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
16
16
|
/**
|
|
17
|
-
*
|
|
17
|
+
* Wraps a React component inside a "higher order" React component that knows how to synchronize your app's JavaScript bundle and image assets when it is mounted.
|
|
18
|
+
*
|
|
19
|
+
* Internally, the higher-order component calls `sync` inside its `componentDidMount` lifecycle handle, which in turns performs an update check, downloads the update if it exists and installs the update for you.
|
|
18
20
|
*
|
|
19
21
|
* @param component the React Component that will be decorated
|
|
20
22
|
*/
|
|
21
23
|
// @ts-ignore
|
|
22
24
|
|
|
23
25
|
/**
|
|
24
|
-
*
|
|
26
|
+
* Wraps a React component inside a "higher order" React component that knows how to synchronize your app's JavaScript bundle and image assets when it is mounted.
|
|
27
|
+
*
|
|
28
|
+
* Internally, the higher-order component calls `sync` inside its `componentDidMount` lifecycle handle, which in turns performs an update check, downloads the update if it exists and installs the update for you.
|
|
25
29
|
*
|
|
26
30
|
* @param options Options used to configure the end-user sync and update experience (e.g. when to check for updates?, show a prompt?, install the update immediately?).
|
|
27
31
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_hoistNonReactStatics","_interopRequireDefault","require","_react","_reactNative","_CheckFrequencyEnum","_notifyAppReady","_sync","_jsxRuntime","e","__esModule","default","withCodePush","optionsOrComponent","options","WithCodePush","RootComponent","CodePushComponent","React","Component","constructor","props","rootComponentRef","createRef","componentDidMount","checkFrequency","CheckFrequency","MANUAL","notifyAppReady","rootComponentInstance","current","syncStatusCallback","codePushStatusDidChange","bind","downloadProgressCallback","codePushDownloadDidProgress","handleBinaryVersionMismatchCallback","codePushOnBinaryVersionMismatch","sync","ON_APP_RESUME","AppState","addEventListener","newState","render","prototype","ref","jsx","hoistStatics","_default","exports"],"sourceRoot":"../../src","sources":["CodePush.tsx"],"mappings":";;;;;;;AAAA,IAAAA,qBAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,MAAA,GAAAF,sBAAA,CAAAC,OAAA;AACA,IAAAE,YAAA,GAAAF,OAAA;AACA,IAAAG,mBAAA,GAAAH,OAAA;AACA,IAAAI,eAAA,GAAAJ,OAAA;AACA,IAAAK,KAAA,GAAAL,OAAA;AAA8B,IAAAM,WAAA,GAAAN,OAAA;AAAA,SAAAD,uBAAAQ,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;
|
|
1
|
+
{"version":3,"names":["_hoistNonReactStatics","_interopRequireDefault","require","_react","_reactNative","_CheckFrequencyEnum","_notifyAppReady","_sync","_jsxRuntime","e","__esModule","default","withCodePush","optionsOrComponent","options","WithCodePush","RootComponent","CodePushComponent","React","Component","constructor","props","rootComponentRef","createRef","componentDidMount","checkFrequency","CheckFrequency","MANUAL","notifyAppReady","rootComponentInstance","current","syncStatusCallback","codePushStatusDidChange","bind","downloadProgressCallback","codePushDownloadDidProgress","handleBinaryVersionMismatchCallback","codePushOnBinaryVersionMismatch","sync","ON_APP_RESUME","AppState","addEventListener","newState","render","prototype","ref","jsx","hoistStatics","_default","exports"],"sourceRoot":"../../src","sources":["CodePush.tsx"],"mappings":";;;;;;;AAAA,IAAAA,qBAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,MAAA,GAAAF,sBAAA,CAAAC,OAAA;AACA,IAAAE,YAAA,GAAAF,OAAA;AACA,IAAAG,mBAAA,GAAAH,OAAA;AACA,IAAAI,eAAA,GAAAJ,OAAA;AACA,IAAAK,KAAA,GAAAL,OAAA;AAA8B,IAAAM,WAAA,GAAAN,OAAA;AAAA,SAAAD,uBAAAQ,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAiB9B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAGA;AACA;AACA;AACA;AACA;AACA;AACA;;AAKO,SAASG,YAAYA,CAAmBC,kBAA4D,EAAE;EAC3G,MAAMC,OAAwB,GAAG,OAAOD,kBAAkB,KAAK,UAAU,GAAG,CAAC,CAAC,GAAGA,kBAAkB;EAEnG,MAAME,YAAY,GAAIC,aAAqC,IAAK;IAC9D,MAAMC,iBAAiB,SAASC,cAAK,CAACC,SAAS,CAAI;MAGjDC,WAAWA,CAACC,KAAY,EAAE;QACxB,KAAK,CAACA,KAAK,CAAC;QACZ,IAAI,CAACC,gBAAgB,gBAAGJ,cAAK,CAACK,SAAS,CAAC,CAAC;MAC3C;MAEAC,iBAAiBA,CAAA,EAAG;QAClB,IAAIV,OAAO,CAACW,cAAc,KAAKC,kCAAc,CAACC,MAAM,EAAE;UACpD,IAAAC,8BAAc,EAAC,CAAC;QAClB,CAAC,MAAM;UACL,MAAMC,qBAAqB,GAAG,IAAI,CAACP,gBAAgB,CAACQ,OAAO;UAE3D,IAAIC,kBAAyD;UAC7D,IAAIF,qBAAqB,IAAIA,qBAAqB,CAACG,uBAAuB,EAAE;YAC1ED,kBAAkB,GAAGF,qBAAqB,CAACG,uBAAuB,CAACC,IAAI,CAACJ,qBAAqB,CAAC;UAChG;UAEA,IAAIK,wBAA8D;UAClE,IAAIL,qBAAqB,IAAIA,qBAAqB,CAACM,2BAA2B,EAAE;YAC9ED,wBAAwB,GAAGL,qBAAqB,CAACM,2BAA2B,CAACF,IAAI,CAACJ,qBAAqB,CAAC;UAC1G;UAEA,IAAIO,mCAAoF;UACxF,IAAIP,qBAAqB,IAAIA,qBAAqB,CAACQ,+BAA+B,EAAE;YAClFD,mCAAmC,GACjCP,qBAAqB,CAACQ,+BAA+B,CAACJ,IAAI,CAACJ,qBAAqB,CAAC;UACrF;UAEA,IAAAS,UAAI,EAACxB,OAAO,EAAEiB,kBAAkB,EAAEG,wBAAwB,EAAEE,mCAAmC,CAAC;UAEhG,IAAItB,OAAO,CAACW,cAAc,KAAKC,kCAAc,CAACa,aAAa,EAAE;YAC3DC,qBAAQ,CAACC,gBAAgB,CAAC,QAAQ,EAAGC,QAAgB,IAAK;cACxD,IAAIA,QAAQ,KAAK,QAAQ,EAAE;gBACzB,IAAAJ,UAAI,EAACxB,OAAO,EAAEiB,kBAAkB,EAAEG,wBAAwB,CAAC;cAC7D;YACF,CAAC,CAAC;UACJ;QACF;MACF;MAEAS,MAAMA,CAAA,EAAG;QACP,MAAMtB,KAAK,GAAG;UAAE,GAAG,IAAI,CAACA;QAAM,CAAC;;QAE/B;QACA;QACA,IAAIL,aAAa,CAAC4B,SAAS,IAAI5B,aAAa,CAAC4B,SAAS,CAACD,MAAM,EAAE;UAC7D;UACAtB,KAAK,CAACwB,GAAG,GAAG,IAAI,CAACvB,gBAAgB;QACnC;QAEA,oBAAO,IAAAd,WAAA,CAAAsC,GAAA,EAAC9B,aAAa;UAAA,GAAKK;QAAK,CAAG,CAAC;MACrC;IACF;IAEA,OAAO,IAAA0B,6BAAY,EAAC9B,iBAAiB,EAAED,aAAa,CAAC;EACvD,CAAC;EAED,IAAI,OAAOH,kBAAkB,KAAK,UAAU,EAAE;IAC5C;IACA,OAAOE,YAAY,CAACF,kBAAkB,CAAC;EACzC,CAAC,MAAM;IACL,OAAOE,YAAY;EACrB;AACF;AAAC,IAAAiC,QAAA,GAAAC,OAAA,CAAAtC,OAAA,GAEcC,YAAY","ignoreList":[]}
|
|
@@ -7,6 +7,8 @@ exports.allowRestart = void 0;
|
|
|
7
7
|
var _NativeRNAppZungCodePushModule = require("./internals/NativeRNAppZungCodePushModule.js");
|
|
8
8
|
/**
|
|
9
9
|
* Allow CodePush to restart the app.
|
|
10
|
+
*
|
|
11
|
+
* This is an advanced API and is only necessary if your app explicitly disallowed restarts via the `disallowRestart` method.
|
|
10
12
|
*/
|
|
11
13
|
const allowRestart = exports.allowRestart = _NativeRNAppZungCodePushModule.NativeRNAppZungCodePushModule.allow;
|
|
12
14
|
//# sourceMappingURL=allowRestart.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_NativeRNAppZungCodePushModule","require","allowRestart","exports","NativeRNAppZungCodePushModule","allow"],"sourceRoot":"../../src","sources":["allowRestart.ts"],"mappings":";;;;;;AAAA,IAAAA,8BAAA,GAAAC,OAAA;AAEA;AACA;AACA;AACO,MAAMC,YAAwB,GAAAC,OAAA,CAAAD,YAAA,GAAGE,4DAA6B,CAACC,KAAK","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["_NativeRNAppZungCodePushModule","require","allowRestart","exports","NativeRNAppZungCodePushModule","allow"],"sourceRoot":"../../src","sources":["allowRestart.ts"],"mappings":";;;;;;AAAA,IAAAA,8BAAA,GAAAC,OAAA;AAEA;AACA;AACA;AACA;AACA;AACO,MAAMC,YAAwB,GAAAC,OAAA,CAAAD,YAAA,GAAGE,4DAA6B,CAACC,KAAK","ignoreList":[]}
|
|
@@ -5,13 +5,13 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.checkForUpdate = checkForUpdate;
|
|
7
7
|
var _reactNative = require("react-native");
|
|
8
|
+
var _CodePushApiSdk = require("./internals/CodePushApiSdk.js");
|
|
8
9
|
var _NativeRNAppZungCodePushModule = require("./internals/NativeRNAppZungCodePushModule.js");
|
|
9
10
|
var _RemotePackageImplementation = require("./internals/RemotePackageImplementation.js");
|
|
10
11
|
var _getConfiguration = require("./internals/getConfiguration.js");
|
|
11
12
|
var _getCurrentPackage = require("./internals/getCurrentPackage.js");
|
|
12
|
-
var _getPromisifiedSdk = require("./internals/getPromisifiedSdk.js");
|
|
13
13
|
var _log = require("./internals/utils/log.js");
|
|
14
|
-
var _requestFetchAdapter = require("./internals/utils/
|
|
14
|
+
var _requestFetchAdapter = require("./internals/utils/requestFetchAdapter.js");
|
|
15
15
|
/**
|
|
16
16
|
* Asks the CodePush service whether the configured app release channel has an update available.
|
|
17
17
|
*
|
|
@@ -38,11 +38,9 @@ async function checkForUpdate(releaseChannelPublicId, handleBinaryVersionMismatc
|
|
|
38
38
|
*/
|
|
39
39
|
const config = releaseChannelPublicId ? {
|
|
40
40
|
...nativeConfig,
|
|
41
|
-
|
|
42
|
-
releaseChannelPublicId
|
|
43
|
-
}
|
|
41
|
+
releaseChannelPublicId
|
|
44
42
|
} : nativeConfig;
|
|
45
|
-
const sdk =
|
|
43
|
+
const sdk = new _CodePushApiSdk.CodePushApiSdk(_requestFetchAdapter.requestFetchAdapter, config);
|
|
46
44
|
const localPackage = await (0, _getCurrentPackage.getCurrentPackage)();
|
|
47
45
|
|
|
48
46
|
/*
|
|
@@ -53,17 +51,12 @@ async function checkForUpdate(releaseChannelPublicId, handleBinaryVersionMismatc
|
|
|
53
51
|
* to send the app version to the server, since we are interested
|
|
54
52
|
* in any updates for current binary version, regardless of hash.
|
|
55
53
|
*/
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
};
|
|
63
|
-
if (_reactNative.Platform.OS === 'ios' && config.packageHash) {
|
|
64
|
-
queryPackage.packageHash = config.packageHash;
|
|
65
|
-
}
|
|
66
|
-
}
|
|
54
|
+
const queryPackage = localPackage ?? {
|
|
55
|
+
appVersion: config.appVersion,
|
|
56
|
+
...(_reactNative.Platform.OS === 'ios' && config.packageHash ? {
|
|
57
|
+
packageHash: config.packageHash
|
|
58
|
+
} : {})
|
|
59
|
+
};
|
|
67
60
|
const update = await sdk.queryUpdateWithCurrentPackage(queryPackage);
|
|
68
61
|
|
|
69
62
|
/*
|
|
@@ -87,19 +80,24 @@ async function checkForUpdate(releaseChannelPublicId, handleBinaryVersionMismatc
|
|
|
87
80
|
if (!update) {
|
|
88
81
|
return null;
|
|
89
82
|
}
|
|
90
|
-
if ('updateAppVersion' in update
|
|
83
|
+
if ('updateAppVersion' in update) {
|
|
84
|
+
if (!update.updateAppVersion) {
|
|
85
|
+
throw new Error('updateAppVersion should never be false');
|
|
86
|
+
}
|
|
91
87
|
(0, _log.log)('An update is available but it is not targeting the binary version of your app.');
|
|
92
88
|
handleBinaryVersionMismatchCallback?.(update);
|
|
93
89
|
return null;
|
|
94
90
|
}
|
|
95
|
-
if (localPackage &&
|
|
91
|
+
if (localPackage && update.packageHash === localPackage.packageHash || (!localPackage || '_isDebugOnly' in localPackage && localPackage._isDebugOnly) && config.packageHash === update.packageHash) {
|
|
96
92
|
return null;
|
|
97
93
|
}
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
94
|
+
const remotePackageData = {
|
|
95
|
+
...update,
|
|
96
|
+
releaseChannelPublicId: releaseChannelPublicId || nativeConfig.releaseChannelPublicId,
|
|
97
|
+
failedInstall: await _NativeRNAppZungCodePushModule.NativeRNAppZungCodePushModule.isFailedUpdate(update.packageHash),
|
|
98
|
+
isFirstRun: false,
|
|
99
|
+
isPending: false
|
|
100
|
+
};
|
|
101
|
+
return new _RemotePackageImplementation.RemotePackageImpl(remotePackageData, packageInfo => sdk.reportStatusDownload(packageInfo));
|
|
104
102
|
}
|
|
105
103
|
//# sourceMappingURL=checkForUpdates.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_reactNative","require","_NativeRNAppZungCodePushModule","_RemotePackageImplementation","_getConfiguration","_getCurrentPackage","
|
|
1
|
+
{"version":3,"names":["_reactNative","require","_CodePushApiSdk","_NativeRNAppZungCodePushModule","_RemotePackageImplementation","_getConfiguration","_getCurrentPackage","_log","_requestFetchAdapter","checkForUpdate","releaseChannelPublicId","handleBinaryVersionMismatchCallback","nativeConfig","getConfiguration","config","sdk","CodePushApiSdk","requestFetchAdapter","localPackage","getCurrentPackage","queryPackage","appVersion","Platform","OS","packageHash","update","queryUpdateWithCurrentPackage","updateAppVersion","Error","log","_isDebugOnly","remotePackageData","failedInstall","NativeRNAppZungCodePushModule","isFailedUpdate","isFirstRun","isPending","RemotePackageImpl","packageInfo","reportStatusDownload"],"sourceRoot":"../../src","sources":["checkForUpdates.ts"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AACA,IAAAC,eAAA,GAAAD,OAAA;AAEA,IAAAE,8BAAA,GAAAF,OAAA;AACA,IAAAG,4BAAA,GAAAH,OAAA;AACA,IAAAI,iBAAA,GAAAJ,OAAA;AACA,IAAAK,kBAAA,GAAAL,OAAA;AAEA,IAAAM,IAAA,GAAAN,OAAA;AACA,IAAAO,oBAAA,GAAAP,OAAA;AAGA;AACA;AACA;AACA;AACA;AACA;AACO,eAAeQ,cAAcA,CAClCC,sBAA+B,EAC/BC,mCAAyE,EAC1C;EAC/B;AACF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;EACE,MAAMC,YAAY,GAAG,MAAM,IAAAC,kCAAgB,EAAC,CAAC;EAC7C;AACF;AACA;AACA;AACA;AACA;AACA;EACE,MAAMC,MAAqB,GAAGJ,sBAAsB,GAAG;IAAE,GAAGE,YAAY;IAAEF;EAAuB,CAAC,GAAGE,YAAY;EACjH,MAAMG,GAAG,GAAG,IAAIC,8BAAc,CAACC,wCAAmB,EAAEH,MAAM,CAAC;EAE3D,MAAMI,YAAY,GAAG,MAAM,IAAAC,oCAAiB,EAAC,CAAC;;EAE9C;AACF;AACA;AACA;AACA;AACA;AACA;AACA;EACE,MAAMC,YAA0C,GAAGF,YAAY,IAAI;IACjEG,UAAU,EAAEP,MAAM,CAACO,UAAU;IAC7B,IAAIC,qBAAQ,CAACC,EAAE,KAAK,KAAK,IAAIT,MAAM,CAACU,WAAW,GAAG;MAAEA,WAAW,EAAEV,MAAM,CAACU;IAAY,CAAC,GAAG,CAAC,CAAC;EAC5F,CAAC;EAED,MAAMC,MAAM,GAAG,MAAMV,GAAG,CAACW,6BAA6B,CAACN,YAAY,CAAC;;EAEpE;AACF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;EACE,IAAI,CAACK,MAAM,EAAE;IACX,OAAO,IAAI;EACb;EAEA,IAAI,kBAAkB,IAAIA,MAAM,EAAE;IAChC,IAAI,CAACA,MAAM,CAACE,gBAAgB,EAAE;MAC5B,MAAM,IAAIC,KAAK,CAAC,wCAAwC,CAAC;IAC3D;IAEA,IAAAC,QAAG,EAAC,gFAAgF,CAAC;IACrFlB,mCAAmC,GAAGc,MAAM,CAAC;IAE7C,OAAO,IAAI;EACb;EAEA,IACGP,YAAY,IAAIO,MAAM,CAACD,WAAW,KAAKN,YAAY,CAACM,WAAW,IAC/D,CAAC,CAACN,YAAY,IAAK,cAAc,IAAIA,YAAY,IAAIA,YAAY,CAACY,YAAa,KAC9EhB,MAAM,CAACU,WAAW,KAAKC,MAAM,CAACD,WAAY,EAC5C;IACA,OAAO,IAAI;EACb;EAEA,MAAMO,iBAAkD,GAAG;IACzD,GAAGN,MAAM;IACTf,sBAAsB,EAAEA,sBAAsB,IAAIE,YAAY,CAACF,sBAAsB;IACrFsB,aAAa,EAAE,MAAMC,4DAA6B,CAACC,cAAc,CAACT,MAAM,CAACD,WAAW,CAAC;IACrFW,UAAU,EAAE,KAAK;IACjBC,SAAS,EAAE;EACb,CAAC;EAED,OAAO,IAAIC,8CAAiB,CAACN,iBAAiB,EAAGO,WAAW,IAAKvB,GAAG,CAACwB,oBAAoB,CAACD,WAAW,CAAC,CAAC;AACzG","ignoreList":[]}
|
|
@@ -7,8 +7,9 @@ exports.clearUpdates = void 0;
|
|
|
7
7
|
var _NativeRNAppZungCodePushModule = require("./internals/NativeRNAppZungCodePushModule.js");
|
|
8
8
|
/**
|
|
9
9
|
* Clears all downloaded CodePush updates.
|
|
10
|
+
*
|
|
10
11
|
* This is useful when switching to a different release channel which may have an older release than the current package.
|
|
11
|
-
* Note: we don’t recommend
|
|
12
|
+
* Note: we don’t recommend using this method in scenarios other than that (CodePush will call
|
|
12
13
|
* this method automatically when needed in other cases) as it could lead to unpredictable behavior.
|
|
13
14
|
*/
|
|
14
15
|
const clearUpdates = exports.clearUpdates = _NativeRNAppZungCodePushModule.NativeRNAppZungCodePushModule.clearUpdates;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_NativeRNAppZungCodePushModule","require","clearUpdates","exports","NativeRNAppZungCodePushModule"],"sourceRoot":"../../src","sources":["clearUpdates.ts"],"mappings":";;;;;;AAAA,IAAAA,8BAAA,GAAAC,OAAA;AAEA;AACA;AACA;AACA;AACA;AACA;AACO,MAAMC,YAAwB,GAAAC,OAAA,CAAAD,YAAA,GAAGE,4DAA6B,CAACF,YAAY","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["_NativeRNAppZungCodePushModule","require","clearUpdates","exports","NativeRNAppZungCodePushModule"],"sourceRoot":"../../src","sources":["clearUpdates.ts"],"mappings":";;;;;;AAAA,IAAAA,8BAAA,GAAAC,OAAA;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,MAAMC,YAAwB,GAAAC,OAAA,CAAAD,YAAA,GAAGE,4DAA6B,CAACF,YAAY","ignoreList":[]}
|
|
@@ -7,6 +7,8 @@ exports.disallowRestart = void 0;
|
|
|
7
7
|
var _NativeRNAppZungCodePushModule = require("./internals/NativeRNAppZungCodePushModule.js");
|
|
8
8
|
/**
|
|
9
9
|
* Forbid CodePush to restart the app.
|
|
10
|
+
*
|
|
11
|
+
* This is an advanced API, and is useful when a component within your app (for example an onboarding process) needs to ensure that no end-user interruptions can occur during its lifetime.
|
|
10
12
|
*/
|
|
11
13
|
const disallowRestart = exports.disallowRestart = _NativeRNAppZungCodePushModule.NativeRNAppZungCodePushModule.disallow;
|
|
12
14
|
//# sourceMappingURL=disallowRestart.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_NativeRNAppZungCodePushModule","require","disallowRestart","exports","NativeRNAppZungCodePushModule","disallow"],"sourceRoot":"../../src","sources":["disallowRestart.ts"],"mappings":";;;;;;AAAA,IAAAA,8BAAA,GAAAC,OAAA;AAEA;AACA;AACA;AACO,MAAMC,eAA2B,GAAAC,OAAA,CAAAD,eAAA,GAAGE,4DAA6B,CAACC,QAAQ","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["_NativeRNAppZungCodePushModule","require","disallowRestart","exports","NativeRNAppZungCodePushModule","disallow"],"sourceRoot":"../../src","sources":["disallowRestart.ts"],"mappings":";;;;;;AAAA,IAAAA,8BAAA,GAAAC,OAAA;AAEA;AACA;AACA;AACA;AACA;AACO,MAAMC,eAA2B,GAAAC,OAAA,CAAAD,eAAA,GAAGE,4DAA6B,CAACC,QAAQ","ignoreList":[]}
|
|
@@ -13,11 +13,11 @@ let CheckFrequency = exports.CheckFrequency = /*#__PURE__*/function (CheckFreque
|
|
|
13
13
|
*/
|
|
14
14
|
CheckFrequency[CheckFrequency["ON_APP_START"] = 0] = "ON_APP_START";
|
|
15
15
|
/**
|
|
16
|
-
* When the app re-enters the foreground.
|
|
16
|
+
* When the app re-enters the foreground after being "backgrounded" (user pressed the home button, app launches a separate payment process, etc.)
|
|
17
17
|
*/
|
|
18
18
|
CheckFrequency[CheckFrequency["ON_APP_RESUME"] = 1] = "ON_APP_RESUME";
|
|
19
19
|
/**
|
|
20
|
-
* Don't automatically check for updates, but only do it when
|
|
20
|
+
* Don't automatically check for updates, but only do it when `sync()` is manually called in app code.
|
|
21
21
|
*/
|
|
22
22
|
CheckFrequency[CheckFrequency["MANUAL"] = 2] = "MANUAL";
|
|
23
23
|
return CheckFrequency;
|
|
@@ -11,16 +11,20 @@ var _NativeRNAppZungCodePushModule = require("../internals/NativeRNAppZungCodePu
|
|
|
11
11
|
let InstallMode = exports.InstallMode = function (InstallMode) {
|
|
12
12
|
/**
|
|
13
13
|
* Indicates that you want to install the update and restart the app immediately.
|
|
14
|
+
*
|
|
15
|
+
* This value is appropriate for debugging scenarios as well as when displaying an update prompt to the user, since they would expect to see the changes immediately after accepting the installation. Additionally, this mode can be used to enforce mandatory updates, since it removes the potentially undesired latency between the update installation and the next time the end user restarts or resumes the app.
|
|
14
16
|
*/
|
|
15
17
|
InstallMode[InstallMode["IMMEDIATE"] = _NativeRNAppZungCodePushModule.NativeRNAppZungCodePushModule.getConstants().codePushInstallModeImmediate] = "IMMEDIATE";
|
|
16
18
|
/**
|
|
17
19
|
* Indicates that you want to install the update, but not forcibly restart the app.
|
|
20
|
+
*
|
|
21
|
+
* When the app is "naturally" restarted (due the OS or end user killing it), the update will be seamlessly picked up. This value is appropriate when performing silent updates, since it would likely be disruptive to the end user if the app suddenly restarted out of nowhere, since they wouldn't have realized an update was even downloaded. This is the default mode used for both the `sync` and `LocalPackage.install` methods.
|
|
18
22
|
*/
|
|
19
23
|
InstallMode[InstallMode["ON_NEXT_RESTART"] = _NativeRNAppZungCodePushModule.NativeRNAppZungCodePushModule.getConstants().codePushInstallModeOnNextRestart] = "ON_NEXT_RESTART";
|
|
20
24
|
/**
|
|
21
|
-
* Indicates that you want to install the update, but don't want to restart the app until the next time
|
|
22
|
-
*
|
|
23
|
-
* but you can get the update in front of them sooner than having to wait for the next natural restart.
|
|
25
|
+
* Indicates that you want to install the update, but don't want to restart the app until the next time the end user resumes it from the background.
|
|
26
|
+
*
|
|
27
|
+
* This way, you don't disrupt their current session,but you can get the update in front of them sooner than having to wait for the next natural restart.
|
|
24
28
|
* This value is appropriate for silent installs that can be applied on resume in a non-invasive way.
|
|
25
29
|
*/
|
|
26
30
|
InstallMode[InstallMode["ON_NEXT_RESUME"] = _NativeRNAppZungCodePushModule.NativeRNAppZungCodePushModule.getConstants().codePushInstallModeOnNextResume] = "ON_NEXT_RESUME";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_NativeRNAppZungCodePushModule","require","InstallMode","exports","NativeRNAppZungCodePushModule","getConstants","codePushInstallModeImmediate","codePushInstallModeOnNextRestart","codePushInstallModeOnNextResume","codePushInstallModeOnNextSuspend"],"sourceRoot":"../../../src","sources":["enums/InstallMode.enum.ts"],"mappings":";;;;;;AAAA,IAAAA,8BAAA,GAAAC,OAAA;AAEA;AACA;AACA;AAFA,IAGYC,WAAW,GAAAC,OAAA,CAAAD,WAAA,aAAXA,WAAW;EACrB;AACF;AACA;
|
|
1
|
+
{"version":3,"names":["_NativeRNAppZungCodePushModule","require","InstallMode","exports","NativeRNAppZungCodePushModule","getConstants","codePushInstallModeImmediate","codePushInstallModeOnNextRestart","codePushInstallModeOnNextResume","codePushInstallModeOnNextSuspend"],"sourceRoot":"../../../src","sources":["enums/InstallMode.enum.ts"],"mappings":";;;;;;AAAA,IAAAA,8BAAA,GAAAC,OAAA;AAEA;AACA;AACA;AAFA,IAGYC,WAAW,GAAAC,OAAA,CAAAD,WAAA,aAAXA,WAAW;EACrB;AACF;AACA;AACA;AACA;EALYA,WAAW,CAAXA,WAAW,gBAMTE,4DAA6B,CAACC,YAAY,CAAC,CAAC,CAACC,4BAA4B;EAErF;AACF;AACA;AACA;AACA;EAZYJ,WAAW,CAAXA,WAAW,sBAaHE,4DAA6B,CAACC,YAAY,CAAC,CAAC,CAACE,gCAAgC;EAE/F;AACF;AACA;AACA;AACA;AACA;EApBYL,WAAW,CAAXA,WAAW,qBAqBJE,4DAA6B,CAACC,YAAY,CAAC,CAAC,CAACG,+BAA+B;EAE7F;AACF;AACA;AACA;AACA;EA3BYN,WAAW,CAAXA,WAAW,sBA4BHE,4DAA6B,CAACC,YAAY,CAAC,CAAC,CAACI,gCAAgC;EAAA,OA5BrFP,WAAW;AAAA","ignoreList":[]}
|
|
@@ -9,26 +9,26 @@ exports.SyncStatus = void 0;
|
|
|
9
9
|
*/
|
|
10
10
|
let SyncStatus = exports.SyncStatus = /*#__PURE__*/function (SyncStatus) {
|
|
11
11
|
/**
|
|
12
|
-
* The app is up-to-date with the
|
|
12
|
+
* The app is fully up-to-date with the configured release channel.
|
|
13
13
|
*/
|
|
14
14
|
SyncStatus[SyncStatus["UP_TO_DATE"] = 0] = "UP_TO_DATE";
|
|
15
15
|
/**
|
|
16
16
|
* An available update has been installed and will be run either immediately after the
|
|
17
|
-
* syncStatusChangedCallback function returns or the next time the app resumes/restarts,
|
|
18
|
-
* depending on the InstallMode specified in SyncOptions
|
|
17
|
+
* `syncStatusChangedCallback` function returns or the next time the app resumes/restarts,
|
|
18
|
+
* depending on the `InstallMode` specified in `SyncOptions`
|
|
19
19
|
*/
|
|
20
20
|
SyncStatus[SyncStatus["UPDATE_INSTALLED"] = 1] = "UPDATE_INSTALLED";
|
|
21
21
|
/**
|
|
22
22
|
* The app had an optional update which the end user chose to ignore.
|
|
23
|
-
* (This is only applicable when the updateDialog is used)
|
|
23
|
+
* (This is only applicable when the `updateDialog` is used)
|
|
24
24
|
*/
|
|
25
25
|
SyncStatus[SyncStatus["UPDATE_IGNORED"] = 2] = "UPDATE_IGNORED";
|
|
26
26
|
/**
|
|
27
|
-
* The sync operation encountered an unknown error.
|
|
27
|
+
* The `sync` operation encountered an unknown error.
|
|
28
28
|
*/
|
|
29
29
|
SyncStatus[SyncStatus["UNKNOWN_ERROR"] = 3] = "UNKNOWN_ERROR";
|
|
30
30
|
/**
|
|
31
|
-
* There is an ongoing sync operation running which prevents the current call from being executed.
|
|
31
|
+
* There is an ongoing `sync` operation running which prevents the current call from being executed.
|
|
32
32
|
*/
|
|
33
33
|
SyncStatus[SyncStatus["SYNC_IN_PROGRESS"] = 4] = "SYNC_IN_PROGRESS";
|
|
34
34
|
/**
|
|
@@ -37,7 +37,7 @@ let SyncStatus = exports.SyncStatus = /*#__PURE__*/function (SyncStatus) {
|
|
|
37
37
|
SyncStatus[SyncStatus["CHECKING_FOR_UPDATE"] = 5] = "CHECKING_FOR_UPDATE";
|
|
38
38
|
/**
|
|
39
39
|
* An update is available, and a confirmation dialog was shown
|
|
40
|
-
* to the end user. (This is only applicable when the updateDialog is used)
|
|
40
|
+
* to the end user. (This is only applicable when the `updateDialog` is used)
|
|
41
41
|
*/
|
|
42
42
|
SyncStatus[SyncStatus["AWAITING_USER_ACTION"] = 6] = "AWAITING_USER_ACTION";
|
|
43
43
|
/**
|
|
@@ -10,18 +10,19 @@ var _NativeRNAppZungCodePushModule = require("../internals/NativeRNAppZungCodePu
|
|
|
10
10
|
*/
|
|
11
11
|
let UpdateState = exports.UpdateState = function (UpdateState) {
|
|
12
12
|
/**
|
|
13
|
-
* Indicates that an update represents the
|
|
14
|
-
*
|
|
13
|
+
* Indicates that an update represents the version of the app that is currently running.
|
|
14
|
+
*
|
|
15
|
+
* This can be useful for identifying attributes about the app, for scenarios such as displaying the release description in a "what's new?" dialog or reporting the latest version to an analytics and/or crash reporting service.
|
|
15
16
|
*/
|
|
16
17
|
UpdateState[UpdateState["RUNNING"] = _NativeRNAppZungCodePushModule.NativeRNAppZungCodePushModule.getConstants().codePushUpdateStateRunning] = "RUNNING";
|
|
17
18
|
/**
|
|
18
|
-
* Indicates than an update has been installed, but the
|
|
19
|
-
*
|
|
19
|
+
* Indicates than an update has been installed, but the app hasn't been restarted yet in order to apply it.
|
|
20
|
+
*
|
|
21
|
+
* This can be useful for determining whether there is a pending update, which you may want to force a programmatic restart (via `restartApp`) in order to apply.
|
|
20
22
|
*/
|
|
21
23
|
UpdateState[UpdateState["PENDING"] = _NativeRNAppZungCodePushModule.NativeRNAppZungCodePushModule.getConstants().codePushUpdateStatePending] = "PENDING";
|
|
22
24
|
/**
|
|
23
|
-
* Indicates than an update represents the latest available
|
|
24
|
-
* release, and can be either currently running or pending.
|
|
25
|
+
* Indicates than an update represents the latest available release, and can be either currently running or pending.
|
|
25
26
|
*/
|
|
26
27
|
UpdateState[UpdateState["LATEST"] = _NativeRNAppZungCodePushModule.NativeRNAppZungCodePushModule.getConstants().codePushUpdateStateLatest] = "LATEST";
|
|
27
28
|
return UpdateState;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_NativeRNAppZungCodePushModule","require","UpdateState","exports","NativeRNAppZungCodePushModule","getConstants","codePushUpdateStateRunning","codePushUpdateStatePending","codePushUpdateStateLatest"],"sourceRoot":"../../../src","sources":["enums/UpdateState.enum.ts"],"mappings":";;;;;;AAAA,IAAAA,8BAAA,GAAAC,OAAA;AAEA;AACA;AACA;AAFA,IAGYC,WAAW,GAAAC,OAAA,CAAAD,WAAA,aAAXA,WAAW;EACrB;AACF;AACA;AACA;
|
|
1
|
+
{"version":3,"names":["_NativeRNAppZungCodePushModule","require","UpdateState","exports","NativeRNAppZungCodePushModule","getConstants","codePushUpdateStateRunning","codePushUpdateStatePending","codePushUpdateStateLatest"],"sourceRoot":"../../../src","sources":["enums/UpdateState.enum.ts"],"mappings":";;;;;;AAAA,IAAAA,8BAAA,GAAAC,OAAA;AAEA;AACA;AACA;AAFA,IAGYC,WAAW,GAAAC,OAAA,CAAAD,WAAA,aAAXA,WAAW;EACrB;AACF;AACA;AACA;AACA;EALYA,WAAW,CAAXA,WAAW,cAMXE,4DAA6B,CAACC,YAAY,CAAC,CAAC,CAACC,0BAA0B;EAEjF;AACF;AACA;AACA;AACA;EAZYJ,WAAW,CAAXA,WAAW,cAaXE,4DAA6B,CAACC,YAAY,CAAC,CAAC,CAACE,0BAA0B;EAEjF;AACF;AACA;EAjBYL,WAAW,CAAXA,WAAW,aAkBZE,4DAA6B,CAACC,YAAY,CAAC,CAAC,CAACG,yBAAyB;EAAA,OAlBrEN,WAAW;AAAA","ignoreList":[]}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.getClientUniqueId = void 0;
|
|
7
|
+
var _getConfiguration = require("./internals/getConfiguration.js");
|
|
8
|
+
/**
|
|
9
|
+
* Gets the client's unique ID set by the module. You may also see `resetClientUniqueId`.
|
|
10
|
+
*/
|
|
11
|
+
const getClientUniqueId = async () => {
|
|
12
|
+
const nativeConfig = await (0, _getConfiguration.getConfiguration)();
|
|
13
|
+
return nativeConfig.clientUniqueId;
|
|
14
|
+
};
|
|
15
|
+
exports.getClientUniqueId = getClientUniqueId;
|
|
16
|
+
//# sourceMappingURL=getClientUniqueId.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_getConfiguration","require","getClientUniqueId","nativeConfig","getConfiguration","clientUniqueId","exports"],"sourceRoot":"../../src","sources":["getClientUniqueId.ts"],"mappings":";;;;;;AAAA,IAAAA,iBAAA,GAAAC,OAAA;AAEA;AACA;AACA;AACO,MAAMC,iBAAiB,GAAG,MAAAA,CAAA,KAAY;EAC3C,MAAMC,YAAY,GAAG,MAAM,IAAAC,kCAAgB,EAAC,CAAC;EAC7C,OAAOD,YAAY,CAACE,cAAc;AACpC,CAAC;AAACC,OAAA,CAAAJ,iBAAA,GAAAA,iBAAA","ignoreList":[]}
|