UNPKG

@logicwind/react-native-tvos-ssl-pinning

Version:
24 lines (23 loc) 1.01 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.fetchDataWithPinning = fetchDataWithPinning; exports.getAvailableCertificates = getAvailableCertificates; var _reactNative = require("react-native"); const LINKING_ERROR = `The package '@logicwind/react-native-tvos-ssl-pinning' doesn't seem to be linked. Make sure: \n\n` + _reactNative.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 ReactNativeTvosSslPinning = _reactNative.NativeModules.ReactNativeTvosSslPinning ? _reactNative.NativeModules.ReactNativeTvosSslPinning : new Proxy({}, { get() { throw new Error(LINKING_ERROR); } }); function getAvailableCertificates() { return ReactNativeTvosSslPinning.getAvailableCertificates(); } function fetchDataWithPinning(url, options) { return ReactNativeTvosSslPinning.fetchDataWithPinning(url, options); } //# sourceMappingURL=index.js.map