expo-asset 10.0.2 → 10.0.3

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,16 @@
10
10
 
11
11
  ### 💡 Others
12
12
 
13
+ ## 10.0.3 — 2024-04-24
14
+
15
+ ### 🐛 Bug fixes
16
+
17
+ - Fix `TypeError: (0, _ExpoAsset.downloadAsync) is not a function` when loading assets using Expo Web. ([#28405](https://github.com/expo/expo/pull/28405) by [@jamiees2](https://github.com/jamiees2))
18
+
19
+ ### 💡 Others
20
+
21
+ - Update mocks for SDK51. ([#28424](https://github.com/expo/expo/pull/28424) by [@aleqsio](https://github.com/aleqsio))
22
+
13
23
  ## 10.0.2 — 2024-04-23
14
24
 
15
25
  _This version does not introduce any user-facing changes._
@@ -1,7 +1,7 @@
1
1
  apply plugin: 'com.android.library'
2
2
 
3
3
  group = 'expo.modules.asset'
4
- version = '10.0.2'
4
+ version = '10.0.3'
5
5
 
6
6
  def expoModulesCorePlugin = new File(project(":expo-modules-core").projectDir.absolutePath, "ExpoModulesCorePlugin.gradle")
7
7
  apply from: expoModulesCorePlugin
@@ -14,6 +14,6 @@ android {
14
14
  namespace "expo.modules.asset"
15
15
  defaultConfig {
16
16
  versionCode 1
17
- versionName "10.0.2"
17
+ versionName "10.0.3"
18
18
  }
19
19
  }
@@ -1,5 +1,2 @@
1
- declare const _default: {
2
- downloadAsync(url: string, _hash: string | null, _type: string): Promise<string>;
3
- };
4
- export default _default;
1
+ export declare function downloadAsync(url: string, _hash: string | null, _type: string): Promise<string>;
5
2
  //# sourceMappingURL=ExpoAsset.web.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ExpoAsset.web.d.ts","sourceRoot":"","sources":["../src/ExpoAsset.web.ts"],"names":[],"mappings":";uBAC2B,MAAM,SAAS,MAAM,GAAG,IAAI,SAAS,MAAM,GAAG,QAAQ,MAAM,CAAC;;AADxF,wBAIE"}
1
+ {"version":3,"file":"ExpoAsset.web.d.ts","sourceRoot":"","sources":["../src/ExpoAsset.web.ts"],"names":[],"mappings":"AAAA,wBAAsB,aAAa,CACjC,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,MAAM,GAAG,IAAI,EACpB,KAAK,EAAE,MAAM,GACZ,OAAO,CAAC,MAAM,CAAC,CAEjB"}
@@ -1,6 +1,4 @@
1
- export default {
2
- async downloadAsync(url, _hash, _type) {
3
- return url;
4
- },
5
- };
1
+ export async function downloadAsync(url, _hash, _type) {
2
+ return url;
3
+ }
6
4
  //# sourceMappingURL=ExpoAsset.web.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ExpoAsset.web.js","sourceRoot":"","sources":["../src/ExpoAsset.web.ts"],"names":[],"mappings":"AAAA,eAAe;IACb,KAAK,CAAC,aAAa,CAAC,GAAW,EAAE,KAAoB,EAAE,KAAa;QAClE,OAAO,GAAG,CAAC;IACb,CAAC;CACF,CAAC","sourcesContent":["export default {\n async downloadAsync(url: string, _hash: string | null, _type: string): Promise<string> {\n return url;\n },\n};\n"]}
1
+ {"version":3,"file":"ExpoAsset.web.js","sourceRoot":"","sources":["../src/ExpoAsset.web.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,KAAK,UAAU,aAAa,CACjC,GAAW,EACX,KAAoB,EACpB,KAAa;IAEb,OAAO,GAAG,CAAC;AACb,CAAC","sourcesContent":["export async function downloadAsync(\n url: string,\n _hash: string | null,\n _type: string\n): Promise<string> {\n return url;\n}\n"]}
@@ -5,8 +5,10 @@
5
5
  * and works out of the box with the expo jest preset.
6
6
  * */
7
7
 
8
+ export type URL = any;
9
+
8
10
  export async function downloadAsync(
9
- url: string,
11
+ url: URL,
10
12
  md5Hash: string | undefined,
11
13
  type: string
12
14
  ): Promise<any> {}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "expo-asset",
3
- "version": "10.0.2",
3
+ "version": "10.0.3",
4
4
  "description": "An Expo universal module to download assets and pass them into other APIs",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",
@@ -50,5 +50,5 @@
50
50
  "peerDependencies": {
51
51
  "expo": "*"
52
52
  },
53
- "gitHead": "ee4f30ef3b5fa567ad1bf94794197f7683fdd481"
53
+ "gitHead": "8b4cb45563b85c2ec91b1b249d136661bf6e8981"
54
54
  }
@@ -1,5 +1,7 @@
1
- export default {
2
- async downloadAsync(url: string, _hash: string | null, _type: string): Promise<string> {
3
- return url;
4
- },
5
- };
1
+ export async function downloadAsync(
2
+ url: string,
3
+ _hash: string | null,
4
+ _type: string
5
+ ): Promise<string> {
6
+ return url;
7
+ }