UNPKG

react-native-epson-escposprinter

Version:
17 lines (16 loc) 891 B
"use strict"; import { DeviceEventEmitter, NativeEventEmitter, NativeModules, Platform } from "react-native"; // @ts-expect-error ts(7017) const isTurboModuleEnabled = global.__turboModuleProxy != null; const NativeInterface = isTurboModuleEnabled ? // eslint-disable-next-line @typescript-eslint/no-require-imports require("./NativeEpsonEscposprinter").default : NativeModules.EpsonEscposprinter; if (!NativeInterface) { throw new Error("The package 'react-native-epson-escposprinter' doesn't seem to be linked. Make sure: \n\n" + Platform.select({ ios: "- You have run 'pod install'\n", default: "" }) + "- You rebuilt the app after installing the package\n" + "- You are not using Expo Go\n"); } const events = isTurboModuleEnabled ? new NativeEventEmitter(NativeInterface) : DeviceEventEmitter; export { events, NativeInterface }; //# sourceMappingURL=NativeInterface.js.map