Skip to content

"Missing Mapbox GL JS CSS" when using with Vue-Cli 3 #36

@brianbancroft

Description

@brianbancroft

Hi there, and thanks for putting something nice like this together.

I've got an issue where the css isn't loading properly, and I receive the following error:

image

The main difference between how I was able to use this library and the docs is that I use the map in a nested component instead of declaring it in the main object in main.js. Instead, from within a MainBody component, I have the Mapbox component defined from within the export default statement. To be clear, the intent is to have the map cover the entire region that is coloured #aaa, but not the part that is white. (Resolved, but the message persists)

From MainBody.vue:

<script>
  import Mapbox from 'mapbox-gl-vue'

  export default {
    components: {
      Mapbox
    }
  }
</script>

Is there something else that I require to do to make the warning message go away, and to allow the map to take the entire right-hand of the screen (as in the screencap)?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions