expo-build-properties 0.5.2 → 0.6.0

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 CHANGED
@@ -10,6 +10,12 @@
10
10
 
11
11
  ### 💡 Others
12
12
 
13
+ ## 0.6.0 — 2023-04-14
14
+
15
+ ### 🎉 New features
16
+
17
+ - Added experimental `unstable_networkInspector` properties. ([#22129](https://github.com/expo/expo/pull/22129) by [@kudo](https://github.com/kudo))
18
+
13
19
  ## 0.5.2 — 2023-04-03
14
20
 
15
21
  ### 🎉 New features
package/build/android.js CHANGED
@@ -58,6 +58,10 @@ exports.withAndroidBuildProperties = createBuildGradlePropsConfigPlugin([
58
58
  propName: 'android.enableShrinkResourcesInReleaseBuilds',
59
59
  propValueGetter: (config) => config.android?.enableShrinkResourcesInReleaseBuilds?.toString(),
60
60
  },
61
+ {
62
+ propName: 'EX_DEV_CLIENT_NETWORK_INSPECTOR',
63
+ propValueGetter: (config) => config.android?.unstable_networkInspector?.toString(),
64
+ },
61
65
  ], 'withAndroidBuildProperties');
62
66
  const withAndroidFlipper = (config, props) => {
63
67
  const ANDROID_FLIPPER_KEY = 'FLIPPER_VERSION';
package/build/ios.js CHANGED
@@ -21,6 +21,10 @@ exports.withIosBuildProperties = createBuildPodfilePropsConfigPlugin([
21
21
  return undefined;
22
22
  },
23
23
  },
24
+ {
25
+ propName: 'EX_DEV_CLIENT_NETWORK_INSPECTOR',
26
+ propValueGetter: (config) => config.ios?.unstable_networkInspector?.toString(),
27
+ },
24
28
  ], 'withIosBuildProperties');
25
29
  const withIosDeploymentTarget = (config, props) => {
26
30
  const deploymentTarget = props.ios?.deploymentTarget;
@@ -60,13 +60,17 @@ export interface PluginConfigTypeAndroid {
60
60
  */
61
61
  packagingOptions?: PluginConfigTypeAndroidPackagingOptions;
62
62
  /**
63
- * By default, Flipper is enabled with the version that comes bundled with `react-native`.
64
- *
65
- * Use this to change the [Flipper](https://fbflipper.com/) version when
66
- * running your app on Android. You can set the `flipper` property to a
67
- * semver string and specify an alternate Flipper version.
63
+ * Change the [Flipper](https://fbflipper.com/) version when running your app on Android.
64
+ * Flipper is by default enabled with the version that comes bundled with react-native.
65
+ * However, you can set the `flipper` property to a semver string and specify an
66
+ * alternate Flipper version.
68
67
  */
69
68
  flipper?: string;
69
+ /**
70
+ * Enable the experimental Network Inspector for [Development builds](https://docs.expo.dev/develop/development-builds/introduction/).
71
+ * SDK 49+ is required.
72
+ */
73
+ unstable_networkInspector?: boolean;
70
74
  }
71
75
  /**
72
76
  * Interface representing available configuration for iOS native build properties.
@@ -87,20 +91,24 @@ export interface PluginConfigTypeIos {
87
91
  * Enable [`use_frameworks!`](https://guides.cocoapods.org/syntax/podfile.html#use_frameworks_bang)
88
92
  * in `Podfile` to use frameworks instead of static libraries for Pods.
89
93
  *
90
- * > You cannot use `useFrameworks` and `flipper` at the same time , and
91
- * doing so will generate an error.
94
+ * Note: You cannot use `useFrameworks` and `flipper` at the same time
92
95
  */
93
96
  useFrameworks?: 'static' | 'dynamic';
94
97
  /**
95
98
  * Enable [Flipper](https://fbflipper.com/) when running your app on iOS in
96
99
  * Debug mode. Setting `true` enables the default version of Flipper, while
97
100
  * setting a semver string will enable a specific version of Flipper you've
98
- * declared in your **package.json**. The default for this configuration is `false`.
101
+ * declared in your package.json. The default for this configuration is `false`.
99
102
  *
100
- * > You cannot use `flipper` at the same time as `useFrameworks`, and
103
+ * Note: You cannot use `flipper` at the same time as `useFrameworks`, and
101
104
  * doing so will generate an error.
102
105
  */
103
106
  flipper?: boolean | string;
107
+ /**
108
+ * Enable the experimental Network Inspector for [Development builds](https://docs.expo.dev/develop/development-builds/introduction/).
109
+ * SDK 49+ is required.
110
+ */
111
+ unstable_networkInspector?: boolean;
104
112
  }
105
113
  /**
106
114
  * Interface representing available configuration for Android Gradle plugin [PackagingOptions](https://developer.android.com/reference/tools/gradle-api/7.0/com/android/build/api/dsl/PackagingOptions).
@@ -50,6 +50,7 @@ const schema = {
50
50
  },
51
51
  nullable: true,
52
52
  },
53
+ unstable_networkInspector: { type: 'boolean', nullable: true },
53
54
  },
54
55
  nullable: true,
55
56
  },
@@ -63,6 +64,7 @@ const schema = {
63
64
  type: ['boolean', 'string'],
64
65
  nullable: true,
65
66
  },
67
+ unstable_networkInspector: { type: 'boolean', nullable: true },
66
68
  },
67
69
  nullable: true,
68
70
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "expo-build-properties",
3
- "version": "0.5.2",
3
+ "version": "0.6.0",
4
4
  "description": "Config plugin to customize native build properties on prebuild",
5
5
  "main": "build/withBuildProperties.js",
6
6
  "types": "build/withBuildProperties.d.ts",
@@ -40,5 +40,5 @@
40
40
  "peerDependencies": {
41
41
  "expo": "*"
42
42
  },
43
- "gitHead": "014aa056080fd88a11b09b5be7c3ba078fbec7d0"
43
+ "gitHead": "6b73082d014ebe93f091aa75cd06f4d4d90eff19"
44
44
  }
package/src/android.ts CHANGED
@@ -63,6 +63,10 @@ export const withAndroidBuildProperties = createBuildGradlePropsConfigPlugin<Plu
63
63
  propName: 'android.enableShrinkResourcesInReleaseBuilds',
64
64
  propValueGetter: (config) => config.android?.enableShrinkResourcesInReleaseBuilds?.toString(),
65
65
  },
66
+ {
67
+ propName: 'EX_DEV_CLIENT_NETWORK_INSPECTOR',
68
+ propValueGetter: (config) => config.android?.unstable_networkInspector?.toString(),
69
+ },
66
70
  ],
67
71
  'withAndroidBuildProperties'
68
72
  );
package/src/ios.ts CHANGED
@@ -23,6 +23,10 @@ export const withIosBuildProperties = createBuildPodfilePropsConfigPlugin<Plugin
23
23
  return undefined;
24
24
  },
25
25
  },
26
+ {
27
+ propName: 'EX_DEV_CLIENT_NETWORK_INSPECTOR',
28
+ propValueGetter: (config) => config.ios?.unstable_networkInspector?.toString(),
29
+ },
26
30
  ],
27
31
  'withIosBuildProperties'
28
32
  );
@@ -81,13 +81,18 @@ export interface PluginConfigTypeAndroid {
81
81
  packagingOptions?: PluginConfigTypeAndroidPackagingOptions;
82
82
 
83
83
  /**
84
- * By default, Flipper is enabled with the version that comes bundled with `react-native`.
85
- *
86
- * Use this to change the [Flipper](https://fbflipper.com/) version when
87
- * running your app on Android. You can set the `flipper` property to a
88
- * semver string and specify an alternate Flipper version.
84
+ * Change the [Flipper](https://fbflipper.com/) version when running your app on Android.
85
+ * Flipper is by default enabled with the version that comes bundled with react-native.
86
+ * However, you can set the `flipper` property to a semver string and specify an
87
+ * alternate Flipper version.
89
88
  */
90
89
  flipper?: string;
90
+
91
+ /**
92
+ * Enable the experimental Network Inspector for [Development builds](https://docs.expo.dev/develop/development-builds/introduction/).
93
+ * SDK 49+ is required.
94
+ */
95
+ unstable_networkInspector?: boolean;
91
96
  }
92
97
 
93
98
  /**
@@ -110,8 +115,7 @@ export interface PluginConfigTypeIos {
110
115
  * Enable [`use_frameworks!`](https://guides.cocoapods.org/syntax/podfile.html#use_frameworks_bang)
111
116
  * in `Podfile` to use frameworks instead of static libraries for Pods.
112
117
  *
113
- * > You cannot use `useFrameworks` and `flipper` at the same time , and
114
- * doing so will generate an error.
118
+ * Note: You cannot use `useFrameworks` and `flipper` at the same time
115
119
  */
116
120
  useFrameworks?: 'static' | 'dynamic';
117
121
 
@@ -119,12 +123,18 @@ export interface PluginConfigTypeIos {
119
123
  * Enable [Flipper](https://fbflipper.com/) when running your app on iOS in
120
124
  * Debug mode. Setting `true` enables the default version of Flipper, while
121
125
  * setting a semver string will enable a specific version of Flipper you've
122
- * declared in your **package.json**. The default for this configuration is `false`.
126
+ * declared in your package.json. The default for this configuration is `false`.
123
127
  *
124
- * > You cannot use `flipper` at the same time as `useFrameworks`, and
128
+ * Note: You cannot use `flipper` at the same time as `useFrameworks`, and
125
129
  * doing so will generate an error.
126
130
  */
127
131
  flipper?: boolean | string;
132
+
133
+ /**
134
+ * Enable the experimental Network Inspector for [Development builds](https://docs.expo.dev/develop/development-builds/introduction/).
135
+ * SDK 49+ is required.
136
+ */
137
+ unstable_networkInspector?: boolean;
128
138
  }
129
139
 
130
140
  /**
@@ -182,6 +192,8 @@ const schema: JSONSchemaType<PluginConfigType> = {
182
192
  },
183
193
  nullable: true,
184
194
  },
195
+
196
+ unstable_networkInspector: { type: 'boolean', nullable: true },
185
197
  },
186
198
  nullable: true,
187
199
  },
@@ -196,6 +208,8 @@ const schema: JSONSchemaType<PluginConfigType> = {
196
208
  type: ['boolean', 'string'],
197
209
  nullable: true,
198
210
  },
211
+
212
+ unstable_networkInspector: { type: 'boolean', nullable: true },
199
213
  },
200
214
  nullable: true,
201
215
  },