You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
importReactfrom'react';import{StyleSheet,View}from'react-native';importMapboxGLfrom'@rnmapbox/maps';conststyles=StyleSheet.create({mapView: {flex: 1},});classBugExampleextendsReact.Component{asynccomponentDidMount(){console.log('>>>>>>>>>>start creating pack',);awaitMapboxGL.offlineManager.createPack({name: 'field-1',// anybounds: [[32.23782523101579,46.39912398458027],[33.43887899585923,47.041693870480955]],// any LARGE areastyleURL: MapboxGL.StyleURL.Street,minZoom: 10,maxZoom: 12,},(pack,status)=>{console.log('>>>>>>>>>>pack progress',pack.name,status.percentage,status.completedTileCount);if(status.state==='completed'){MapboxGL.offlineManager.deletePack('field-1');// throws error where deletePack is not a function (android only)}},(pack,error)=>{console.log('>>>>>>>>>>pack error',pack.name,error);},);// always shows a single pack without metadata nor identifier (name)console.log(MapboxGL.offlineManager.getPacks());// HERE's where the error is thrownawaitMapboxGL.offlineManager.invalidatePack('field-1')}render(){return(<Viewstyle={styles.mapView}><MapboxGL.MapViewref={(c)=>(this._map=c)}onPress={this.onPress}style={styles.mapView}><MapboxGL.CamerazoomLevel={10}centerCoordinate={[33.43887899585923,47.041693870480955]}/></MapboxGL.MapView></View>);}}exportdefaultBugExample;
Observed behavior and steps to reproduce
Example of the error thrown below:
Expected behavior
await Mapbox.offlineManager.invalidatePack(packName) should be implemented.
Notes / preliminary analysis
await Mapbox.offlineManager.invalidatePack(packName) is not implemented and throws a JS function is undefined error.
Additional links and references
No response
The text was updated successfully, but these errors were encountered:
chris-gaona
changed the title
[BUG]: OfflineManager.invalidatePack is not implemented
[BUG]: offlineManager.invalidatePack is not implemented
Jun 14, 2023
Am able to downloading the maps like I gave multiple map boundaries and along with multiple names . After that app memory size was increased then I want to delete few offline maps so am using this one
MapboxGL.offlineManager.deletePack('field-1')
using whatever i used names for create offline map , but name only deleting along with data was not deleted , while check the app memory still same size is there .
So I want how to delete the offline map from the app ambient cache memory
Mapbox Implementation
Mapbox
Mapbox Version
default
Platform
iOS
@rnmapbox/maps
version10.0.7
Standalone component to reproduce
Observed behavior and steps to reproduce
Example of the error thrown below:
Expected behavior
await Mapbox.offlineManager.invalidatePack(packName) should be implemented.
Notes / preliminary analysis
await Mapbox.offlineManager.invalidatePack(packName) is not implemented and throws a JS function is undefined error.
Additional links and references
No response
The text was updated successfully, but these errors were encountered: