@gfean/react-native-bundle-drop 0.1.32 → 0.1.34

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.
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const react_native_1 = require("react-native");
4
+ const injectImageResolver_1 = require("./injectImageResolver");
5
+ const patchImageAutoResolve_1 = require("./patchImageAutoResolve");
6
+ (() => {
7
+ if (react_native_1.Platform.OS !== 'android') {
8
+ return;
9
+ }
10
+ // Apply the shared resolver/renderer patches early during app startup.
11
+ (0, injectImageResolver_1.injectBundleDropImageResolver)();
12
+ (0, patchImageAutoResolve_1.patchImageRenderToForceResolve)();
13
+ })();
package/lib/index.d.ts CHANGED
@@ -49,3 +49,4 @@ export declare function initUpdateManager(opts?: {
49
49
  }): Promise<void>;
50
50
  export type { BundleInfo } from './bundleInfo';
51
51
  export type { UpdatePolicy } from './types';
52
+ export { useBundleDrop } from './useBundleDrop';
package/lib/index.js CHANGED
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.getUpdateState = exports.applyReadyUpdate = exports.downloadUpdate = exports.restartAppAndInstallUpdate = void 0;
6
+ exports.useBundleDrop = exports.getUpdateState = exports.applyReadyUpdate = exports.downloadUpdate = exports.restartAppAndInstallUpdate = void 0;
7
7
  exports.getDownloadedBundlePath = getDownloadedBundlePath;
8
8
  exports.checkForUpdate = checkForUpdate;
9
9
  exports.getInstalledBundleInfo = getInstalledBundleInfo;
@@ -413,3 +413,6 @@ async function initUpdateManager(opts) {
413
413
  // Final check to report install for already-applied bundles (deduped by lastInstalledReportedHash).
414
414
  await reportInstalledIfReady();
415
415
  }
416
+ // Hooks
417
+ var useBundleDrop_1 = require("./useBundleDrop");
418
+ Object.defineProperty(exports, "useBundleDrop", { enumerable: true, get: function () { return useBundleDrop_1.useBundleDrop; } });
package/package.json CHANGED
@@ -1,16 +1,28 @@
1
1
  {
2
2
  "name": "@gfean/react-native-bundle-drop",
3
- "version": "0.1.32",
3
+ "version": "0.1.34",
4
4
  "description": "react native ota by gFean",
5
5
  "main": "lib/index.js",
6
6
  "types": "lib/index.d.ts",
7
7
  "author": " <> ()",
8
8
  "license": "UNLICENSED",
9
9
  "homepage": "https://github.com/GFean/react-native-bundle-drop",
10
+ "exports": {
11
+ ".": {
12
+ "types": "./lib/index.d.ts",
13
+ "default": "./lib/index.js"
14
+ },
15
+ "./bootstrap": {
16
+ "types": "./lib/bootstrap.d.ts",
17
+ "default": "./lib/bootstrap.js"
18
+ },
19
+ "./package.json": "./package.json"
20
+ },
10
21
  "scripts": {
11
22
  "clean": "rimraf lib dist",
12
23
  "build": "tsc -p tsconfig.json && node scripts/make-cli-executable.js",
13
- "prepublishOnly": "yarn clean && yarn build"
24
+ "prepublishOnly": "yarn clean && yarn build",
25
+ "build-and-publish": "yarn clean && yarn build && npm publish --access=restricted"
14
26
  },
15
27
  "create-react-native-library": {
16
28
  "type": "legacy-module",