Skip to content

[Bug]: StyleImport overrides styleURL and fails over to default basemap #4180

@afgarcia86

Description

@afgarcia86

Mapbox Version

default

React Native Version

0.83.2

Platform

iOS

@rnmapbox/maps version

10.3.0

Standalone component to reproduce

import React from 'react';
import {
  MapView,
  StyleImport,
  Camera,
} from '@rnmapbox/maps';


const styleUrl = ""

class BugReportExample extends React.Component {
  render() {
    return (
      <MapView style={{flex: 1}} styleURL={styleUrl}>
        <Camera centerCoordinate={[-74.00597, 40.71427]} zoomLevel={14} />
        <StyleImport
            id="basemap"
            existing
            config={{
              lightPreset: 'night',
            }}
        /> 
      </MapView>
    );
  }
}

Observed behavior and steps to reproduce

No response

Expected behavior

Changes current style's lightPreset

Notes / preliminary analysis

No response

Additional links and references

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug 🪲Something isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions