How to use the expo-file-system.EncodingTypes function in expo-file-system

To help you get started, we’ve selected a few expo-file-system 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 expo / browser-polyfill / src / DOM / HTMLImageElement.js View on Github external
import { Image } from 'react-native';
import * as FileSystem from 'expo-file-system';
const { writeAsStringAsync, documentDirectory } = FileSystem;
const EncodingType = FileSystem.EncodingType || FileSystem.EncodingTypes;

import uuidv1 from 'uuid/v1';

import Element from './Element';

const b64Extensions = {
  '/': 'jpg',
  i: 'png',
  R: 'gif',
  U: 'webp',
};

function b64WithoutPrefix(b64) {
  return b64.split(',')[1];
}