I was able to do this using the visualVariables property in a SimpleRenderer (I even threw in an offset for the lines):
var linkRenderer = new SimpleRenderer({
symbol: {
type: "cim",
// CIM Line Symbol
data: {
type: "CIMSymbolReference",
symbol: {
type: "CIMLineSymbol",
symbolLayers: [{
type: "CIMSolidStroke",
enable: true,
color: [213,157,30,255],
effects: [{
type: "CIMGeometricEffectOffset",
offset: 3.0,
method: "Rounded",
option: "Fast"
}]
}]
}
}
}, visualVariables: [
{
type: "color",
valueExpression: "$feature.voltr_"+ comparison_year + " - $feature.voltr_" + reference_year,
stops: [
{value: 3000,color: "#ffa500"},
{value: 1,color: "#ffe3af"},
{value: 0,color: "white"},
{value: -1,color: "#e0e9f1"},
{value: -4400,color: "#4b6791"},
{value: -9900,color: "#1d1e22"}
]
}
]
});