JSFiddle - React, Tailwind, and code Playground

by Alex Azuero

HTML

<!DOCTYPE html>
<html>

<head>
	<title></title>
	<link rel="stylesheet" href="http://js.arcgis.com/3.15/esri/css/esri.css">
	<style>
		html,
body,
#mapDiv {
	height: 100%;
	width: 100%;
	margin: 0;
	padding: 0;
}

#basemapGalleryDiv {
	position: absolute;
	top: 100px;
	right: 10px;
	height: 300px;
	width: 400px;
	overflow-y: scroll;
	overflow-x: hidden;
	border-radius: 17px;
	border: 2px solid #4A668B;
	background: #2B4970;
	box-shadow: #B3B3B3 2px 2px 2px;
	padding: 14px 0px 14px 7px;
}

#legendContainer {
	position: absolute;
	top: 100px;
	left: 10px;
	height: 300px;
	width: 300px;
	overflow-y: scroll;
	overflow-x: hidden;
	border-radius: 17px;
	background: #fff;
	box-shadow: #B3B3B3 2px 2px 2px;
	padding: 14px 0px 14px 7px;
}

#basemapGalleryDiv .esriBasemapGallerySelectedNode .esriBasemapGalleryThumbnail {
	border: 4px solid #F99;
	margin: 0;
}
	</style>

	<script src="http://js.arcgis.com/3.15/"></script>
	<script>
	require([
        "esri/map",
        "esri/dijit/BasemapGallery",
        "esri/dijit/Legend",
        "esri/layers/ArcGISTiledMapServiceLayer",
        "esri/layers/ArcGISDynamicMapServiceLayer",
        "esri/layers/FeatureLayer",
        "dojo/on",
        "dojo/domReady!"],
	function (
        Map,
		BasemapGallery,
		Legend,
		ArcGISTiledMapServiceLayer,
		ArcGISDynamicMapServiceLayer,
		FeatureLayer,
		on) {
				var map = new Map("mapDiv", {
					showAttribution: false, //sources false or true
					logo: false //esri logo
          //basemap: "light-gray"
				});
				var tileMap = new ArcGISTiledMapServiceLayer("http://maps.ngdc.noaa.gov/arcgis/rest/services/web_mercator/etopo1_hillshade/MapServer");
				
        
          var DHS = new ArcGISDynamicMapServiceLayer("http://129.2.24.163:6080/arcgis/rest/services/GEOG655_S2016/Aazuero_IMR/MapServer", {
					"id": "DHS",
					"opacity": 1,
				});
             
        var worldCities = new...