Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

239
Visualizações
React Native Map WMSTile Offline not working

I try to use my map on offline. On google layers, react-native-maps does it on its own. I also use a tile server for marine map. The server works with the WMS format and the library offers a WMSTile component (Unfortunately no specific example of use... ).

This component accepts a setting offlinemode and tileCachePath, I am not sure of the implementation and it does not work for offline.

<WMSTile
urlTemplate={MY_URL_TEMPLATE}
shouldReplaceMapContent={false}
tileCachePath={`${RNFS.CachesDirectoryPath}/tiles`}
offlineMode={true}
tileSize={256}
/>

MapScreen.tsx

useEffect(() => {
exists(`${RNFS.CachesDirectoryPath}/tiles`)
.then(exist => {
if (!exist){
mkdir(`${RNFS.CachesDirectoryPath}/tiles`)
}
})
})

App.tsx

When launching the application, check if a tiles folder exists because it is the one I specify to my WMSTile component but prioritizes it is not the right way.

For system files, I use react-native-fs

Thank you for your help

about 4 years ago · Santiago Gelvez
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda