How to use the @react-native-firebase/common.isArray function in @react-native-firebase/common

To help you get started, we’ve selected a few @react-native-firebase/common examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github invertase / react-native-firebase / packages / ml-vision / lib / VisionCloudDocumentTextRecognizerOptions.js View on Github external
setLanguageHints(hintedLanguages) {
    // quick check the first entry is a string only
    if (!isArray(hintedLanguages) || !hintedLanguages.length || !isString(hintedLanguages[0])) {
      throw new Error(
        `firebase.mlKitVision() VisionCloudTextRecognizerOptions.setLanguageHints(*) 'hintedLanguages' must be an non empty array of strings.`,
      );
    }

    return this.set('hintedLanguages', hintedLanguages);
  }
}