title: Ggplot and sf for overlaying two layers of polygons (.shp)
body: <p>I have two polygon '.shp' files. I need one to appear on the map by filling in one variable and the other to appear only on borders, overlapping the first.</p>
  
  <p>I have already used 'ggplot2' and 'sf'.</p>
  
  <p>I plotted a map ('map1'), which is layered with polygons, using 'ggplot' and 'geom_sf'.</p>
  
  <p>I use a variable ('var1') contained in 'map1' as a 'fill'.</p>
  
  <p>Now, I need to add (overlay) another layer of polygons on top ('map2'). This will have to be 'transparent fill' or 'no fill'. Only appearing the outline of the borders.</p>
  
  <pre><code>library(ggplot2); library(sf)
  
  map1 &lt;- st_read("m1.shp") #reading polygon layer map 1
  
  map2 &lt;- st_read("m2.shp")#reading polygon layer map 2 
  
  g &lt;- ggplot(map1, aes(fill = var1)) + 
      geom_sf() 
  </code></pre>
  
  <p>How can i add 'map2' for overlay this map? </p>
  
  <p>The idea would be:</p>
  
  <pre><code>g &lt;- ggplot(map1, aes(fill = var1)) + 
      geom_sf() +
  ggplot(map2, aes()) + 
      geom_sf() 
  
  #Error: Don't know how to add ggplot(map2, aes()) to a plot
  </code></pre>