UNPKG

react-native-mapsforge-vtm

Version:

React Native components to build vector maps using Mapsforges fork of vtm. Offline rendering of OpenStreetMap data. Android only

17 lines (15 loc) 373 B
"use strict"; /** * External dependencies */ import { useRef, useEffect } from 'react'; // https://blog.logrocket.com/accessing-previous-props-state-react-hooks/ const usePrevious = value => { const ref = useRef(); useEffect(() => { ref.current = value; }, [value]); return ref.current; }; export default usePrevious; //# sourceMappingURL=usePrevious.js.map