expo-application 58.0.4 → 58.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/CHANGELOG.md +13 -0
- package/android/build.gradle +2 -2
- package/build/Application.d.ts +20 -2
- package/build/Application.js +22 -0
- package/build/Application.js.map +1 -1
- package/build/Application.types.d.ts +16 -0
- package/expo-module.config.json +0 -3
- package/ios/ApplicationModule.swift +22 -0
- package/local-maven-repo/host/exp/exponent/expo.modules.application/{58.0.4/expo.modules.application-58.0.4.module → 58.1.1/expo.modules.application-58.1.1.module} +7 -7
- package/local-maven-repo/host/exp/exponent/expo.modules.application/58.1.1/expo.modules.application-58.1.1.module.md5 +1 -0
- package/local-maven-repo/host/exp/exponent/expo.modules.application/58.1.1/expo.modules.application-58.1.1.module.sha1 +1 -0
- package/local-maven-repo/host/exp/exponent/expo.modules.application/58.1.1/expo.modules.application-58.1.1.module.sha256 +1 -0
- package/local-maven-repo/host/exp/exponent/expo.modules.application/58.1.1/expo.modules.application-58.1.1.module.sha512 +1 -0
- package/local-maven-repo/host/exp/exponent/expo.modules.application/{58.0.4/expo.modules.application-58.0.4.pom → 58.1.1/expo.modules.application-58.1.1.pom} +1 -1
- package/local-maven-repo/host/exp/exponent/expo.modules.application/58.1.1/expo.modules.application-58.1.1.pom.md5 +1 -0
- package/local-maven-repo/host/exp/exponent/expo.modules.application/58.1.1/expo.modules.application-58.1.1.pom.sha1 +1 -0
- package/local-maven-repo/host/exp/exponent/expo.modules.application/58.1.1/expo.modules.application-58.1.1.pom.sha256 +1 -0
- package/local-maven-repo/host/exp/exponent/expo.modules.application/58.1.1/expo.modules.application-58.1.1.pom.sha512 +1 -0
- package/package.json +4 -4
- package/src/Application.ts +26 -0
- package/src/Application.types.ts +17 -0
- package/local-maven-repo/host/exp/exponent/expo.modules.application/58.0.4/expo.modules.application-58.0.4.module.md5 +0 -1
- package/local-maven-repo/host/exp/exponent/expo.modules.application/58.0.4/expo.modules.application-58.0.4.module.sha1 +0 -1
- package/local-maven-repo/host/exp/exponent/expo.modules.application/58.0.4/expo.modules.application-58.0.4.module.sha256 +0 -1
- package/local-maven-repo/host/exp/exponent/expo.modules.application/58.0.4/expo.modules.application-58.0.4.module.sha512 +0 -1
- package/local-maven-repo/host/exp/exponent/expo.modules.application/58.0.4/expo.modules.application-58.0.4.pom.md5 +0 -1
- package/local-maven-repo/host/exp/exponent/expo.modules.application/58.0.4/expo.modules.application-58.0.4.pom.sha1 +0 -1
- package/local-maven-repo/host/exp/exponent/expo.modules.application/58.0.4/expo.modules.application-58.0.4.pom.sha256 +0 -1
- package/local-maven-repo/host/exp/exponent/expo.modules.application/58.0.4/expo.modules.application-58.0.4.pom.sha512 +0 -1
- /package/local-maven-repo/host/exp/exponent/expo.modules.application/{58.0.4/expo.modules.application-58.0.4-sources.jar → 58.1.1/expo.modules.application-58.1.1-sources.jar} +0 -0
- /package/local-maven-repo/host/exp/exponent/expo.modules.application/{58.0.4/expo.modules.application-58.0.4-sources.jar.md5 → 58.1.1/expo.modules.application-58.1.1-sources.jar.md5} +0 -0
- /package/local-maven-repo/host/exp/exponent/expo.modules.application/{58.0.4/expo.modules.application-58.0.4-sources.jar.sha1 → 58.1.1/expo.modules.application-58.1.1-sources.jar.sha1} +0 -0
- /package/local-maven-repo/host/exp/exponent/expo.modules.application/{58.0.4/expo.modules.application-58.0.4-sources.jar.sha256 → 58.1.1/expo.modules.application-58.1.1-sources.jar.sha256} +0 -0
- /package/local-maven-repo/host/exp/exponent/expo.modules.application/{58.0.4/expo.modules.application-58.0.4-sources.jar.sha512 → 58.1.1/expo.modules.application-58.1.1-sources.jar.sha512} +0 -0
- /package/local-maven-repo/host/exp/exponent/expo.modules.application/{58.0.4/expo.modules.application-58.0.4.aar → 58.1.1/expo.modules.application-58.1.1.aar} +0 -0
- /package/local-maven-repo/host/exp/exponent/expo.modules.application/{58.0.4/expo.modules.application-58.0.4.aar.md5 → 58.1.1/expo.modules.application-58.1.1.aar.md5} +0 -0
- /package/local-maven-repo/host/exp/exponent/expo.modules.application/{58.0.4/expo.modules.application-58.0.4.aar.sha1 → 58.1.1/expo.modules.application-58.1.1.aar.sha1} +0 -0
- /package/local-maven-repo/host/exp/exponent/expo.modules.application/{58.0.4/expo.modules.application-58.0.4.aar.sha256 → 58.1.1/expo.modules.application-58.1.1.aar.sha256} +0 -0
- /package/local-maven-repo/host/exp/exponent/expo.modules.application/{58.0.4/expo.modules.application-58.0.4.aar.sha512 → 58.1.1/expo.modules.application-58.1.1.aar.sha512} +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,18 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 58.1.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [Internal] Bump precompiled artifacts due to ABI breakage in expo-modules-jsi, which makes `JavaScriptValue` a non-copyable struct. ([#51368](https://github.com/expo/expo/pull/51368) by [@tsapeta](https://github.com/tsapeta))
|
|
8
|
+
- [iOS] Remove the module class declarations from `expo-module.config.json`. Autolinking now detects the `@ExpoModule`-annotated classes. ([#49784](https://github.com/expo/expo/pull/49784) by [@tsapeta](https://github.com/tsapeta))
|
|
9
|
+
|
|
10
|
+
## 58.1.0
|
|
11
|
+
|
|
12
|
+
### Minor Changes
|
|
13
|
+
|
|
14
|
+
- [iOS] Add `getAppleStoreEnvironmentAsync()`, which returns StoreKit's App Store environment for the running build (`'production'`, `'sandbox'` or `'xcode'`), so apps can tell TestFlight, App Review and development builds apart from App Store releases. ([#51209](https://github.com/expo/expo/pull/51209) by [@huntie](https://github.com/huntie))
|
|
15
|
+
|
|
3
16
|
## 58.0.4
|
|
4
17
|
|
|
5
18
|
### Patch Changes
|
package/android/build.gradle
CHANGED
|
@@ -4,7 +4,7 @@ plugins {
|
|
|
4
4
|
}
|
|
5
5
|
|
|
6
6
|
group = 'host.exp.exponent'
|
|
7
|
-
version = '58.
|
|
7
|
+
version = '58.1.1'
|
|
8
8
|
|
|
9
9
|
expoModule {
|
|
10
10
|
v2 true
|
|
@@ -14,7 +14,7 @@ android {
|
|
|
14
14
|
namespace "expo.modules.application"
|
|
15
15
|
defaultConfig {
|
|
16
16
|
versionCode 12
|
|
17
|
-
versionName '58.
|
|
17
|
+
versionName '58.1.1'
|
|
18
18
|
}
|
|
19
19
|
}
|
|
20
20
|
|
package/build/Application.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ApplicationReleaseType, PushNotificationServiceEnvironment } from './Application.types';
|
|
1
|
+
import type { ApplicationReleaseType, PushNotificationServiceEnvironment, AppleAppStoreEnvironment } from './Application.types';
|
|
2
2
|
/**
|
|
3
3
|
* The human-readable version of the native application that may be displayed in the app store.
|
|
4
4
|
* At time when native app is built, on Android, this is the version name set by `version`
|
|
@@ -91,6 +91,24 @@ export declare function getIosIdForVendorAsync(): Promise<string | null>;
|
|
|
91
91
|
* @platform ios
|
|
92
92
|
*/
|
|
93
93
|
export declare function getIosApplicationReleaseTypeAsync(): Promise<ApplicationReleaseType>;
|
|
94
|
+
/**
|
|
95
|
+
* Gets the App Store environment of the running build. Unlike
|
|
96
|
+
* [`getIosApplicationReleaseTypeAsync`](#applicationgetiosapplicationreleasetypeasync), which
|
|
97
|
+
* reports `APP_STORE` for both a TestFlight build and an App Store release, this tells them apart.
|
|
98
|
+
* In Expo Go, this reports Expo Go's own environment.
|
|
99
|
+
*
|
|
100
|
+
* @example
|
|
101
|
+
* ```ts
|
|
102
|
+
* if ((await Application.getAppleStoreEnvironmentAsync()) === 'sandbox') {
|
|
103
|
+
* // Show settings for TestFlight testers, App Review and development builds
|
|
104
|
+
* }
|
|
105
|
+
* ```
|
|
106
|
+
* @return A `Promise` which fulfills with an
|
|
107
|
+
* [`AppleAppStoreEnvironment`](#appleappstoreenvironment).
|
|
108
|
+
* @platform ios
|
|
109
|
+
* @platform tvos
|
|
110
|
+
*/
|
|
111
|
+
export declare function getAppleStoreEnvironmentAsync(): Promise<AppleAppStoreEnvironment>;
|
|
94
112
|
/**
|
|
95
113
|
* Gets the current [Apple Push Notification (APN)](https://developer.apple.com/documentation/bundleresources/entitlements/aps-environment?language=objc)
|
|
96
114
|
* service environment.
|
|
@@ -130,4 +148,4 @@ export declare function getInstallationTimeAsync(): Promise<Date>;
|
|
|
130
148
|
* @platform android
|
|
131
149
|
*/
|
|
132
150
|
export declare function getLastUpdateTimeAsync(): Promise<Date>;
|
|
133
|
-
export { ApplicationReleaseType, type PushNotificationServiceEnvironment, } from './Application.types';
|
|
151
|
+
export { ApplicationReleaseType, type PushNotificationServiceEnvironment, type AppleAppStoreEnvironment, } from './Application.types';
|
package/build/Application.js
CHANGED
|
@@ -112,6 +112,28 @@ import ExpoApplication from './ExpoApplication';
|
|
|
112
112
|
}
|
|
113
113
|
return await ExpoApplication.getApplicationReleaseTypeAsync();
|
|
114
114
|
}
|
|
115
|
+
/**
|
|
116
|
+
* Gets the App Store environment of the running build. Unlike
|
|
117
|
+
* [`getIosApplicationReleaseTypeAsync`](#applicationgetiosapplicationreleasetypeasync), which
|
|
118
|
+
* reports `APP_STORE` for both a TestFlight build and an App Store release, this tells them apart.
|
|
119
|
+
* In Expo Go, this reports Expo Go's own environment.
|
|
120
|
+
*
|
|
121
|
+
* @example
|
|
122
|
+
* ```ts
|
|
123
|
+
* if ((await Application.getAppleStoreEnvironmentAsync()) === 'sandbox') {
|
|
124
|
+
* // Show settings for TestFlight testers, App Review and development builds
|
|
125
|
+
* }
|
|
126
|
+
* ```
|
|
127
|
+
* @return A `Promise` which fulfills with an
|
|
128
|
+
* [`AppleAppStoreEnvironment`](#appleappstoreenvironment).
|
|
129
|
+
* @platform ios
|
|
130
|
+
* @platform tvos
|
|
131
|
+
*/ export async function getAppleStoreEnvironmentAsync() {
|
|
132
|
+
if (!ExpoApplication.getStoreEnvironmentAsync) {
|
|
133
|
+
throw new UnavailabilityError('expo-application', 'getStoreEnvironmentAsync');
|
|
134
|
+
}
|
|
135
|
+
return await ExpoApplication.getStoreEnvironmentAsync();
|
|
136
|
+
}
|
|
115
137
|
// @needsAudit
|
|
116
138
|
/**
|
|
117
139
|
* Gets the current [Apple Push Notification (APN)](https://developer.apple.com/documentation/bundleresources/entitlements/aps-environment?language=objc)
|
package/build/Application.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["Application.ts"],"sourcesContent":[null],"names":["Platform","UnavailabilityError","ExpoApplication","nativeApplicationVersion","nativeBuildVersion","applicationName","applicationId","getAndroidId","OS","androidId","getInstallReferrerAsync","getIosIdForVendorAsync","getIosApplicationReleaseTypeAsync","getApplicationReleaseTypeAsync","getIosPushNotificationServiceEnvironmentAsync","getPushNotificationServiceEnvironmentAsync","getInstallationTimeAsync","installationTime","Date","getLastUpdateTimeAsync","lastUpdateTime","ApplicationReleaseType"],"mappings":"AAAA,SAASA,QAAQ,EAAEC,mBAAmB,QAAQ,OAAO;
|
|
1
|
+
{"version":3,"sources":["Application.ts"],"sourcesContent":[null],"names":["Platform","UnavailabilityError","ExpoApplication","nativeApplicationVersion","nativeBuildVersion","applicationName","applicationId","getAndroidId","OS","androidId","getInstallReferrerAsync","getIosIdForVendorAsync","getIosApplicationReleaseTypeAsync","getApplicationReleaseTypeAsync","getAppleStoreEnvironmentAsync","getStoreEnvironmentAsync","getIosPushNotificationServiceEnvironmentAsync","getPushNotificationServiceEnvironmentAsync","getInstallationTimeAsync","installationTime","Date","getLastUpdateTimeAsync","lastUpdateTime","ApplicationReleaseType"],"mappings":"AAAA,SAASA,QAAQ,EAAEC,mBAAmB,QAAQ,OAAO;AAOrD,OAAOC,qBAAqB,oBAAoB;AAEhD,cAAc;AACd;;;;;;;CAOC,GACD,OAAO,MAAMC,2BAA0CD,kBACnDA,gBAAgBC,wBAAwB,IAAI,OAC5C,KAAK;AAET,cAAc;AACd;;;;;;;;CAQC,GACD,OAAO,MAAMC,qBAAoCF,kBAC7CA,gBAAgBE,kBAAkB,IAAI,OACtC,KAAK;AAET,cAAc;AACd;;;;;;CAMC,GACD,OAAO,MAAMC,kBAAiCH,kBAC1CA,gBAAgBG,eAAe,IAAI,OACnC,KAAK;AAET,cAAc;AACd;;;;;CAKC,GACD,OAAO,MAAMC,gBAA+BJ,kBACxCA,gBAAgBI,aAAa,IAAI,OACjC,KAAK;AAET,cAAc;AACd;;;;;;;;;;;;;;;;CAgBC,GACD,OAAO,SAASC;IACd,IAAIP,SAASQ,EAAE,KAAK,WAAW;QAC7B,MAAM,IAAIP,oBAAoB,oBAAoB;IACpD;IACA,OAAOC,gBAAgBO,SAAS;AAClC;AAEA,cAAc;AACd;;;;;;;;;;;CAWC,GACD,OAAO,eAAeC;IACpB,IAAI,CAACR,gBAAgBQ,uBAAuB,EAAE;QAC5C,MAAM,IAAIT,oBAAoB,oBAAoB;IACpD;IACA,OAAO,MAAMC,gBAAgBQ,uBAAuB;AACtD;AAEA,cAAc;AACd;;;;;;;;;;;;;;;;;;;CAmBC,GACD,OAAO,eAAeC;IACpB,IAAI,CAACT,gBAAgBS,sBAAsB,EAAE;QAC3C,MAAM,IAAIV,oBAAoB,oBAAoB;IACpD;IACA,OAAO,MAAMC,gBAAgBS,sBAAsB;AACrD;AAEA,cAAc;AACd;;;;CAIC,GACD,OAAO,eAAeC;IACpB,IAAI,CAACV,gBAAgBW,8BAA8B,EAAE;QACnD,MAAM,IAAIZ,oBAAoB,oBAAoB;IACpD;IACA,OAAO,MAAMC,gBAAgBW,8BAA8B;AAC7D;AAEA;;;;;;;;;;;;;;;;CAgBC,GACD,OAAO,eAAeC;IACpB,IAAI,CAACZ,gBAAgBa,wBAAwB,EAAE;QAC7C,MAAM,IAAId,oBAAoB,oBAAoB;IACpD;IACA,OAAO,MAAMC,gBAAgBa,wBAAwB;AACvD;AAEA,cAAc;AACd;;;;;;CAMC,GACD,OAAO,eAAeC;IACpB,IAAI,CAACd,gBAAgBe,0CAA0C,EAAE;QAC/D,MAAM,IAAIhB,oBAAoB,oBAAoB;IACpD;IACA,OAAO,MAAMC,gBAAgBe,0CAA0C;AACzE;AAEA,cAAc;AACd;;;;;;;;;;;;;;;;CAgBC,GACD,OAAO,eAAeC;IACpB,IAAI,CAAChB,gBAAgBgB,wBAAwB,EAAE;QAC7C,MAAM,IAAIjB,oBAAoB,oBAAoB;IACpD;IACA,MAAMkB,mBAAmB,MAAMjB,gBAAgBgB,wBAAwB;IACvE,OAAO,IAAIE,KAAKD;AAClB;AAEA,cAAc;AACd;;;;;;;;;;;CAWC,GACD,OAAO,eAAeE;IACpB,IAAI,CAACnB,gBAAgBmB,sBAAsB,EAAE;QAC3C,MAAM,IAAIpB,oBAAoB,oBAAoB;IACpD;IACA,MAAMqB,iBAAiB,MAAMpB,gBAAgBmB,sBAAsB;IACnE,OAAO,IAAID,KAAKE;AAClB;AAEA,SACEC,sBAAsB,QAGjB,sBAAsB"}
|
|
@@ -14,3 +14,19 @@ export declare enum ApplicationReleaseType {
|
|
|
14
14
|
* @platform ios
|
|
15
15
|
*/
|
|
16
16
|
export type PushNotificationServiceEnvironment = 'development' | 'production' | null;
|
|
17
|
+
/**
|
|
18
|
+
* Maps to StoreKit's
|
|
19
|
+
* [`AppStore.Environment`](https://developer.apple.com/documentation/storekit/appstore/environment),
|
|
20
|
+
* as reported by the app's
|
|
21
|
+
* [`AppTransaction.environment`](https://developer.apple.com/documentation/storekit/apptransaction/environment).
|
|
22
|
+
* - `'production'`: An App Store release.
|
|
23
|
+
* - `'sandbox'`: A TestFlight build, a build under App Store Review, or a development, ad hoc, or
|
|
24
|
+
* enterprise-signed build.
|
|
25
|
+
* - `'xcode'`: A build run with a StoreKit configuration file in Xcode.
|
|
26
|
+
* - `null`: StoreKit returns no verified app transaction, or an environment that this version does
|
|
27
|
+
* not recognize. A missing transaction happens on a simulator without a StoreKit configuration
|
|
28
|
+
* file, or when the user is offline or signed out of the App Store before StoreKit caches one.
|
|
29
|
+
* @platform ios
|
|
30
|
+
* @platform tvos
|
|
31
|
+
*/
|
|
32
|
+
export type AppleAppStoreEnvironment = 'production' | 'sandbox' | 'xcode' | null;
|
package/expo-module.config.json
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
// Copyright 2018-present 650 Industries. All rights reserved.
|
|
2
2
|
import ExpoModulesCore
|
|
3
|
+
import StoreKit
|
|
3
4
|
|
|
4
5
|
@ExpoModule("ExpoApplication")
|
|
5
6
|
public class ApplicationModule: Module {
|
|
@@ -58,6 +59,27 @@ public class ApplicationModule: Module {
|
|
|
58
59
|
return mainProvisioningProfile.appReleaseType().rawValue
|
|
59
60
|
}
|
|
60
61
|
|
|
62
|
+
@JS(.concurrent)
|
|
63
|
+
func getStoreEnvironmentAsync() async -> String? {
|
|
64
|
+
guard case .verified(let transaction) = try? await AppTransaction.shared else {
|
|
65
|
+
return nil
|
|
66
|
+
}
|
|
67
|
+
return Self.storeEnvironment(transaction.environment)
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
static func storeEnvironment(_ environment: AppStore.Environment) -> String? {
|
|
71
|
+
switch environment {
|
|
72
|
+
case .production:
|
|
73
|
+
return "production"
|
|
74
|
+
case .sandbox:
|
|
75
|
+
return "sandbox"
|
|
76
|
+
case .xcode:
|
|
77
|
+
return "xcode"
|
|
78
|
+
default:
|
|
79
|
+
return nil
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
|
|
61
83
|
@JS(.concurrent)
|
|
62
84
|
func getPushNotificationServiceEnvironmentAsync() async -> String? {
|
|
63
85
|
let mainProvisioningProfile = EXProvisioningProfile.main()
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"component": {
|
|
4
4
|
"group": "host.exp.exponent",
|
|
5
5
|
"module": "expo.modules.application",
|
|
6
|
-
"version": "58.
|
|
6
|
+
"version": "58.1.1",
|
|
7
7
|
"attributes": {
|
|
8
8
|
"org.gradle.status": "release"
|
|
9
9
|
}
|
|
@@ -24,8 +24,8 @@
|
|
|
24
24
|
},
|
|
25
25
|
"files": [
|
|
26
26
|
{
|
|
27
|
-
"name": "expo.modules.application-58.
|
|
28
|
-
"url": "expo.modules.application-58.
|
|
27
|
+
"name": "expo.modules.application-58.1.1.aar",
|
|
28
|
+
"url": "expo.modules.application-58.1.1.aar",
|
|
29
29
|
"size": 18123,
|
|
30
30
|
"sha512": "f89769b47863dd16fc59557e328743dbd5e940cbb6a580586b64a52604770f8c9ed27f0573084a9dda31c99da2fe666dbb384320f2bad1aeff7b23cb409cae28",
|
|
31
31
|
"sha256": "6c42277423ac93c44f93cb6ffc5b99cbaef685a34694c35df18fea38439991d0",
|
|
@@ -74,8 +74,8 @@
|
|
|
74
74
|
],
|
|
75
75
|
"files": [
|
|
76
76
|
{
|
|
77
|
-
"name": "expo.modules.application-58.
|
|
78
|
-
"url": "expo.modules.application-58.
|
|
77
|
+
"name": "expo.modules.application-58.1.1.aar",
|
|
78
|
+
"url": "expo.modules.application-58.1.1.aar",
|
|
79
79
|
"size": 18123,
|
|
80
80
|
"sha512": "f89769b47863dd16fc59557e328743dbd5e940cbb6a580586b64a52604770f8c9ed27f0573084a9dda31c99da2fe666dbb384320f2bad1aeff7b23cb409cae28",
|
|
81
81
|
"sha256": "6c42277423ac93c44f93cb6ffc5b99cbaef685a34694c35df18fea38439991d0",
|
|
@@ -94,8 +94,8 @@
|
|
|
94
94
|
},
|
|
95
95
|
"files": [
|
|
96
96
|
{
|
|
97
|
-
"name": "expo.modules.application-58.
|
|
98
|
-
"url": "expo.modules.application-58.
|
|
97
|
+
"name": "expo.modules.application-58.1.1-sources.jar",
|
|
98
|
+
"url": "expo.modules.application-58.1.1-sources.jar",
|
|
99
99
|
"size": 2703,
|
|
100
100
|
"sha512": "86e8ef7389ea58be85069e0cc92af6dce9397066c05ff5ef82cbc94319ac21123569e1215983df172e7f8450856e8371f29f311eb4c9258e603f5d9fdb0f07ff",
|
|
101
101
|
"sha256": "4e6b197ea81366e4ce706c9bf316457bb0a6dffab7a035f91dbeb4376dd0c6f1",
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
0d2a3714be3a3796b68953bd625be785
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
2522ae0fa9f348ad959b8bf471c3443dcdce6341
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
a22a696feaf99f38f8455dc958eb13dfff99b57766508f5feee2369b488cd5f0
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
4d88d5a66a528a8012f649cc1db2e9880b3f8455efccb0ab8aef2c9825d8cb7ac36d584af7e208f10adff0c90c1ed0b77584f9676c972d7422128b99d38447f9
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
<modelVersion>4.0.0</modelVersion>
|
|
10
10
|
<groupId>host.exp.exponent</groupId>
|
|
11
11
|
<artifactId>expo.modules.application</artifactId>
|
|
12
|
-
<version>58.
|
|
12
|
+
<version>58.1.1</version>
|
|
13
13
|
<packaging>aar</packaging>
|
|
14
14
|
<name>expo.modules.application</name>
|
|
15
15
|
<url>https://github.com/expo/expo</url>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
d1ad1c80a599191743df39af1ba87a59
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
9170fd9665a39d2f37d75e7151d6b4110677faa7
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
5c51b1529aa689559fbe829edb4a399aee1e48911d1a074c2b9872a932f32323
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
01f6cc25eb3bb322445e68228ce4ce5677cae72d9e6fbb966c46f4076eeaf8f2c0d11ad69de4143dd783e985456b20b767ba8e1a045cb1c1a265ba5d3c51df7f
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "expo-application",
|
|
3
|
-
"version": "58.
|
|
3
|
+
"version": "58.1.1",
|
|
4
4
|
"description": "A universal module that gets native application information such as its ID, app name, and build version at runtime",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"expo",
|
|
@@ -33,9 +33,9 @@
|
|
|
33
33
|
},
|
|
34
34
|
"dependencies": {},
|
|
35
35
|
"devDependencies": {
|
|
36
|
-
"expo": "58.0.
|
|
37
|
-
"expo
|
|
38
|
-
"expo-modules-cli": "0.2.
|
|
36
|
+
"@expo/internal-scripts": "58.0.1",
|
|
37
|
+
"expo": "58.0.8",
|
|
38
|
+
"expo-modules-cli": "0.2.2"
|
|
39
39
|
},
|
|
40
40
|
"peerDependencies": {
|
|
41
41
|
"expo": "*"
|
package/src/Application.ts
CHANGED
|
@@ -3,6 +3,7 @@ import { Platform, UnavailabilityError } from 'expo';
|
|
|
3
3
|
import type {
|
|
4
4
|
ApplicationReleaseType,
|
|
5
5
|
PushNotificationServiceEnvironment,
|
|
6
|
+
AppleAppStoreEnvironment,
|
|
6
7
|
} from './Application.types';
|
|
7
8
|
import ExpoApplication from './ExpoApplication';
|
|
8
9
|
|
|
@@ -142,6 +143,30 @@ export async function getIosApplicationReleaseTypeAsync(): Promise<ApplicationRe
|
|
|
142
143
|
return await ExpoApplication.getApplicationReleaseTypeAsync();
|
|
143
144
|
}
|
|
144
145
|
|
|
146
|
+
/**
|
|
147
|
+
* Gets the App Store environment of the running build. Unlike
|
|
148
|
+
* [`getIosApplicationReleaseTypeAsync`](#applicationgetiosapplicationreleasetypeasync), which
|
|
149
|
+
* reports `APP_STORE` for both a TestFlight build and an App Store release, this tells them apart.
|
|
150
|
+
* In Expo Go, this reports Expo Go's own environment.
|
|
151
|
+
*
|
|
152
|
+
* @example
|
|
153
|
+
* ```ts
|
|
154
|
+
* if ((await Application.getAppleStoreEnvironmentAsync()) === 'sandbox') {
|
|
155
|
+
* // Show settings for TestFlight testers, App Review and development builds
|
|
156
|
+
* }
|
|
157
|
+
* ```
|
|
158
|
+
* @return A `Promise` which fulfills with an
|
|
159
|
+
* [`AppleAppStoreEnvironment`](#appleappstoreenvironment).
|
|
160
|
+
* @platform ios
|
|
161
|
+
* @platform tvos
|
|
162
|
+
*/
|
|
163
|
+
export async function getAppleStoreEnvironmentAsync(): Promise<AppleAppStoreEnvironment> {
|
|
164
|
+
if (!ExpoApplication.getStoreEnvironmentAsync) {
|
|
165
|
+
throw new UnavailabilityError('expo-application', 'getStoreEnvironmentAsync');
|
|
166
|
+
}
|
|
167
|
+
return await ExpoApplication.getStoreEnvironmentAsync();
|
|
168
|
+
}
|
|
169
|
+
|
|
145
170
|
// @needsAudit
|
|
146
171
|
/**
|
|
147
172
|
* Gets the current [Apple Push Notification (APN)](https://developer.apple.com/documentation/bundleresources/entitlements/aps-environment?language=objc)
|
|
@@ -207,4 +232,5 @@ export async function getLastUpdateTimeAsync(): Promise<Date> {
|
|
|
207
232
|
export {
|
|
208
233
|
ApplicationReleaseType,
|
|
209
234
|
type PushNotificationServiceEnvironment,
|
|
235
|
+
type AppleAppStoreEnvironment,
|
|
210
236
|
} from './Application.types';
|
package/src/Application.types.ts
CHANGED
|
@@ -16,3 +16,20 @@ export enum ApplicationReleaseType {
|
|
|
16
16
|
* @platform ios
|
|
17
17
|
*/
|
|
18
18
|
export type PushNotificationServiceEnvironment = 'development' | 'production' | null;
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Maps to StoreKit's
|
|
22
|
+
* [`AppStore.Environment`](https://developer.apple.com/documentation/storekit/appstore/environment),
|
|
23
|
+
* as reported by the app's
|
|
24
|
+
* [`AppTransaction.environment`](https://developer.apple.com/documentation/storekit/apptransaction/environment).
|
|
25
|
+
* - `'production'`: An App Store release.
|
|
26
|
+
* - `'sandbox'`: A TestFlight build, a build under App Store Review, or a development, ad hoc, or
|
|
27
|
+
* enterprise-signed build.
|
|
28
|
+
* - `'xcode'`: A build run with a StoreKit configuration file in Xcode.
|
|
29
|
+
* - `null`: StoreKit returns no verified app transaction, or an environment that this version does
|
|
30
|
+
* not recognize. A missing transaction happens on a simulator without a StoreKit configuration
|
|
31
|
+
* file, or when the user is offline or signed out of the App Store before StoreKit caches one.
|
|
32
|
+
* @platform ios
|
|
33
|
+
* @platform tvos
|
|
34
|
+
*/
|
|
35
|
+
export type AppleAppStoreEnvironment = 'production' | 'sandbox' | 'xcode' | null;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
69623e6ca43ebeee537712810759358c
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
1470b11cfbe7c7b692b38806f8bbccefb1fdb394
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
d3f4feecb6404f6cd57637e27c5f8782a2175080f3a8d5424770d0d832bff4a8
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
28358f0723b7e0741b2298679ec67b5fa531fbc6b5db3187875666f8a36cbb88e0f631dc7faaee43079ceed1594e0ce67f02156c06be8a9f7e4f55d12ef9209a
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
f7f1c533cc1fe8c85e5da17a4c4f0f32
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
d32a00d5b0a2f15bdd35c69cd2c0854a9928983d
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
91103830b98af49c9777e55f9cf06de7430f5bb48d35f7eed5fcca791b15e4f6
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
a992d37cf5f0b25e66fec5e1a891f8456b4d77aacf4c132f2f1741a413a8e065f81de070e1df9467157f331a93e4e13f0e948c54c06b69756f91cfee03c81626
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|