AnsweredAssumed Answered

Any changes to renderer 4.1 and 4.2?

Question asked by Mark_S_B on Feb 15, 2017
Latest reply on Feb 15, 2017 by rscheitlin

Hi All

I have a web map and I am trying to work out why a graphic layer is not rendered when using 4.2. It works fine in 4.0 and 4.1, the code I am using:


        var sppURL = " ";     
        var renderer = new UniqueValueRenderer({
          field: "SLD",
          //defaultSymbol: new SimpleFillSymbol({color:null, outline: null})
        // Add a unique value info
          new SimpleFillSymbol({
            color: [51, 160, 44, 0.6],
               style: "solid",
            outline: null

          value: 2,
          symbol: new SimpleFillSymbol({
            color: [235, 232, 53, 0.6],
            outline: null

      var sppLyr = new MapImageLayer({
          url: sppURL,
          popupTemplate: {
            content: "[*]"
          sublayers: [
          visible: true,
          definitionExpression: "ID = 'SppID'"


       var resultsLayer = new GraphicsLayer({renderer: renderer});



When switching to 4.2 api I get the following error (in Firefox):


Uncaught TypeError: Cannot read property 'type' of null
    at f.get [as isPolygonMarkerSymbol] (MapView.js:365)
    at f._projectGeometry (MapView.js:369)
    at f.render (MapView.js:367)
    at d.renderChild (MapView.js:364)
    at d.renderChildren (MapView.js:259)
    at d.render (MapView.js:255)
    at m.renderChild (MapView.js:290)
    at m.d.renderChildren (MapView.js:259)
    at m.d.render (MapView.js:255)
    at m.render (MapView.js:289)


Any advice welcome as not sure what to do now.