Files
iNaturalistReactNative/react-native-logs.config.js
Amanda Bullington 9544eab730 Email debug logs from About screen; log sign in and sign out (#370)
* Set up logging for user signing in and out
* Set up button to email debug logs in About; closes #357
* Fix bug where signOut called too many times in App; code cleanup
* Add mocks to RNFS to get Auth tests passing
* Add simple test to make sure mailer is called on button press
* Added a file sharing fallback when Mail is not available in iOS
* Rename log extension

Co-authored-by: Ken-ichi Ueda <kenichi.ueda@gmail.com>
2023-01-18 10:59:54 -08:00

24 lines
398 B
JavaScript

import RNFS from "react-native-fs";
import {
fileAsyncTransport,
logger
} from "react-native-logs";
const fileName = "inaturalist-rn-log.txt";
const logFilePath = `${RNFS.DocumentDirectoryPath}/${fileName}`;
const config = {
transport: fileAsyncTransport,
transportOptions: {
FS: RNFS,
fileName
}
};
const log = logger.createLogger( config );
export {
log,
logFilePath
};