I am trying to insert sharepoint list items in UL. right now each item is added in separate UL. please help how to iterate and add all sharepoint list item in one UL.
public componentDidMount(){
if(this.props.Dropdownprop != undefined){
}
alert("second" + this.props.Dropdownprop);
var reactHandler = this;
$.ajax({
url: "https://sharepointprod.sharepoint.com/teams/SharepointPOC/_api/lists(guid'"+this.props.Dropdownprop+"')/items",
type: "GET",
headers:{'Accept': 'application/json; odata=verbose;'},
success: function(resultData) {
reactHandler.setState({
items: resultData.d.results,
});
},
error : function(jqXHR, textStatus, errorThrown) {
}
});
}
public render(): React.ReactElement<IScrollTickerWebPartProps> {
return (
<div>
{this.state.items.map(function(item,key){
return (<div className={styles.marquee} key={key}>
<span>
<div>
<ul className={styles.jsnews}>
<li>{item.Title}</li>
</ul>
</div>
</span>
</div>);
})}
</div>
);
}