<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Proper Way to Load WMSLayer in ArcGIS JSAPI 4.12? in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/proper-way-to-load-wmslayer-in-arcgis-jsapi-4-12/m-p/309160#M28392</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm getting&amp;nbsp;'#load() Failed to load layer TypeError: Cannot read property 'indexOf' of undefined'&amp;nbsp;error when I tried to load WMSLayer in my application.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've tried several different WMS service URLs but with no positive results. The code from the&amp;nbsp;&lt;A href="https://developers.arcgis.com/javascript/latest/sample-code/layers-wms/index.html" rel="nofollow noreferrer"&gt;official sample&lt;/A&gt;&amp;nbsp;doesn't work either.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A&amp;nbsp;&lt;A _jive_internal="true" href="https://community.esri.com/thread/240102-how-to-add-a-ogc-wms-layer-to-application-using-javascript-api-412" rel="nofollow noreferrer"&gt;similar question&lt;/A&gt;&amp;nbsp;has been asked and someone suggested that using proxy might solve the issue, but implementing proxy seems to be a quite complicated process. Please note that the URL in the question has&amp;nbsp;http&amp;nbsp;instead of&amp;nbsp;https&amp;nbsp;like in my application, the error is different from what I'm getting as well.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Does anyone figure out what I'm doing wrong or anything I missed out?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here's my code :&lt;/P&gt;&lt;PRE class="" style="color: #393318; background-color: #eff0f1; border: 0px; margin: 0px 0px 1em; padding: 12px 8px;"&gt;&lt;CODE style="background-color: #eff0f1; border: 0px; font-weight: inherit;"&gt;&lt;SPAN class="" style="color: #101094; border: 0px; font-weight: inherit; font-size: 13px;"&gt;let&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; wmsLayer &lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;=&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #101094; border: 0px; font-weight: inherit; font-size: 13px;"&gt;new&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #2b91af; border: 0px; font-weight: inherit; font-size: 13px;"&gt;WMSLayer&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;({&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    title&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #7d2727; border: 0px; font-weight: inherit; font-size: 13px;"&gt;"WMS Layer"&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    url&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #7d2727; border: 0px; font-weight: inherit; font-size: 13px;"&gt;"https://ows.terrestris.de/osm/service"&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    sublayers&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;[{&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;        name&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #7d2727; border: 0px; font-weight: inherit; font-size: 13px;"&gt;"OSM-WMS"&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    &lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;}]&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;});&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;&lt;/SPAN&gt;&lt;SPAN class="" style="color: #101094; border: 0px; font-weight: inherit; font-size: 13px;"&gt;var&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; basemap &lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;=&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #101094; border: 0px; font-weight: inherit; font-size: 13px;"&gt;new&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #2b91af; border: 0px; font-weight: inherit; font-size: 13px;"&gt;Basemap&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;({&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    baseLayers&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;[&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;wmsLayer&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;]&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;});&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;&lt;/SPAN&gt;&lt;SPAN class="" style="color: #101094; border: 0px; font-weight: inherit; font-size: 13px;"&gt;var&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; map &lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;=&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #101094; border: 0px; font-weight: inherit; font-size: 13px;"&gt;new&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #2b91af; border: 0px; font-weight: inherit; font-size: 13px;"&gt;Map&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;({&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    basemap&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; basemap&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    layers&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;[&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;gridLayer&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; forceSymbolLayer&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; measurementLayer&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; sketchLayer&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;]&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;});&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;&lt;/SPAN&gt;&lt;SPAN class="" style="color: #101094; border: 0px; font-weight: inherit; font-size: 13px;"&gt;var&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; mapView &lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;=&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #101094; border: 0px; font-weight: inherit; font-size: 13px;"&gt;new&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #2b91af; border: 0px; font-weight: inherit; font-size: 13px;"&gt;MapView&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;({&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    map&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; map&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    zoom&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; initZoom&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    center&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; initPosition&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;});&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 12 Dec 2019 08:04:26 GMT</pubDate>
    <dc:creator>JerryChen</dc:creator>
    <dc:date>2019-12-12T08:04:26Z</dc:date>
    <item>
      <title>Proper Way to Load WMSLayer in ArcGIS JSAPI 4.12?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/proper-way-to-load-wmslayer-in-arcgis-jsapi-4-12/m-p/309160#M28392</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm getting&amp;nbsp;'#load() Failed to load layer TypeError: Cannot read property 'indexOf' of undefined'&amp;nbsp;error when I tried to load WMSLayer in my application.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've tried several different WMS service URLs but with no positive results. The code from the&amp;nbsp;&lt;A href="https://developers.arcgis.com/javascript/latest/sample-code/layers-wms/index.html" rel="nofollow noreferrer"&gt;official sample&lt;/A&gt;&amp;nbsp;doesn't work either.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A&amp;nbsp;&lt;A _jive_internal="true" href="https://community.esri.com/thread/240102-how-to-add-a-ogc-wms-layer-to-application-using-javascript-api-412" rel="nofollow noreferrer"&gt;similar question&lt;/A&gt;&amp;nbsp;has been asked and someone suggested that using proxy might solve the issue, but implementing proxy seems to be a quite complicated process. Please note that the URL in the question has&amp;nbsp;http&amp;nbsp;instead of&amp;nbsp;https&amp;nbsp;like in my application, the error is different from what I'm getting as well.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Does anyone figure out what I'm doing wrong or anything I missed out?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here's my code :&lt;/P&gt;&lt;PRE class="" style="color: #393318; background-color: #eff0f1; border: 0px; margin: 0px 0px 1em; padding: 12px 8px;"&gt;&lt;CODE style="background-color: #eff0f1; border: 0px; font-weight: inherit;"&gt;&lt;SPAN class="" style="color: #101094; border: 0px; font-weight: inherit; font-size: 13px;"&gt;let&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; wmsLayer &lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;=&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #101094; border: 0px; font-weight: inherit; font-size: 13px;"&gt;new&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #2b91af; border: 0px; font-weight: inherit; font-size: 13px;"&gt;WMSLayer&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;({&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    title&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #7d2727; border: 0px; font-weight: inherit; font-size: 13px;"&gt;"WMS Layer"&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    url&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #7d2727; border: 0px; font-weight: inherit; font-size: 13px;"&gt;"https://ows.terrestris.de/osm/service"&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    sublayers&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;[{&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;        name&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #7d2727; border: 0px; font-weight: inherit; font-size: 13px;"&gt;"OSM-WMS"&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    &lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;}]&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;});&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;&lt;/SPAN&gt;&lt;SPAN class="" style="color: #101094; border: 0px; font-weight: inherit; font-size: 13px;"&gt;var&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; basemap &lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;=&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #101094; border: 0px; font-weight: inherit; font-size: 13px;"&gt;new&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #2b91af; border: 0px; font-weight: inherit; font-size: 13px;"&gt;Basemap&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;({&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    baseLayers&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;[&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;wmsLayer&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;]&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;});&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;&lt;/SPAN&gt;&lt;SPAN class="" style="color: #101094; border: 0px; font-weight: inherit; font-size: 13px;"&gt;var&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; map &lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;=&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #101094; border: 0px; font-weight: inherit; font-size: 13px;"&gt;new&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #2b91af; border: 0px; font-weight: inherit; font-size: 13px;"&gt;Map&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;({&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    basemap&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; basemap&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    layers&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;[&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;gridLayer&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; forceSymbolLayer&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; measurementLayer&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; sketchLayer&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;]&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;});&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;&lt;/SPAN&gt;&lt;SPAN class="" style="color: #101094; border: 0px; font-weight: inherit; font-size: 13px;"&gt;var&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; mapView &lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;=&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #101094; border: 0px; font-weight: inherit; font-size: 13px;"&gt;new&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #2b91af; border: 0px; font-weight: inherit; font-size: 13px;"&gt;MapView&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;({&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    map&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; map&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    zoom&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; initZoom&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;    center&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;:&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt; initPosition&lt;/SPAN&gt;&lt;SPAN class="" style="color: #303336; border: 0px; font-weight: inherit; font-size: 13px;"&gt;});&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Dec 2019 08:04:26 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/proper-way-to-load-wmslayer-in-arcgis-jsapi-4-12/m-p/309160#M28392</guid>
      <dc:creator>JerryChen</dc:creator>
      <dc:date>2019-12-12T08:04:26Z</dc:date>
    </item>
    <item>
      <title>Re: Proper Way to Load WMSLayer in ArcGIS JSAPI 4.12?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/proper-way-to-load-wmslayer-in-arcgis-jsapi-4-12/m-p/309161#M28393</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Jerry,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I created a codepen from the code you provided above, but removed the other layers (because I did not have their information):&amp;nbsp;&lt;A class="link-titled" href="https://codepen.io/annefitz/pen/ZEYppzq" title="https://codepen.io/annefitz/pen/ZEYppzq"&gt;https://codepen.io/annefitz/pen/ZEYppzq&lt;/A&gt;&amp;nbsp; The WMSLayer seems to load fine in this sample. Is the error coming from one of your other layers?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Anne&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 Dec 2019 21:41:05 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/proper-way-to-load-wmslayer-in-arcgis-jsapi-4-12/m-p/309161#M28393</guid>
      <dc:creator>AnneFitz</dc:creator>
      <dc:date>2019-12-13T21:41:05Z</dc:date>
    </item>
  </channel>
</rss>

