Filter empty continents directly in GraphQL query
This commit is contained in:
@@ -23,7 +23,7 @@
|
||||
$: globeResolution = innerWidth > 1440 && window.devicePixelRatio > 1 ? '4k' : '2k'
|
||||
|
||||
const { continents, locations } = getContext('global')
|
||||
const randomContinent: any = getRandomItem(continents.filter((cont: any) => cont.countries))
|
||||
const randomContinent: any = getRandomItem(continents)
|
||||
const markers = locations.map(({ name, slug, country, coordinates: { coordinates }}): Marker => ({
|
||||
name,
|
||||
slug,
|
||||
|
||||
Reference in New Issue
Block a user