only loading first line from json file

I imitate the example from Jose Leon to make a web app and connect it with data from a server. For the json file i set the TWebClientConnection.URI = 'https://jsonplaceholder.typicode.com/photos'.
I Also add a TWebTableControl and a TWEbClientDataSet on the form.

unit UFrmMain;

interface

uses
System.SysUtils, System.Classes, JS, Web, WEBLib.Graphics, WEBLib.Controls,
WEBLib.Forms, WEBLib.Dialogs, Vcl.StdCtrls, WEBLib.StdCtrls, Vcl.Controls,
WEBLib.WebCtrls, WEBLib.REST, WEBLib.Grids, Vcl.Grids, WEBLib.DBCtrls,
WEBLib.DB, WEBLib.CDS, DB;

type
TForm1 = class(TWebForm)
WebTableControl1: TWebTableControl;
WebDataSource1: TWebDataSource;
cds: TWebClientDataSet;
conn: TWebClientConnection;
procedure cdsAfterOpen(DataSet: TDataSet);
private
{ Private declarations }
public
{ Public declarations }
procedure populateTable;
end;

var
Form1: TForm1;

implementation

{$R *.dfm}

procedure TForm1.cdsAfterOpen(DataSet: TDataSet);
begin
populateTable;
end;

procedure TForm1.populateTable;
var
i: integer;
cell: string;
begin
i := 0;
repeat
cell := format(
'

    '+
    '
  • %s
  • '+
    '
  • %s
  • '+
    '
  • %s
  • '+
    '
'+
'
',[
cds.FieldByName('title').AsString,
cds.FieldByName('url').AsString,
cds.FieldByName('thumbnailUrl').AsString
]);

  WebTableControl1.Cells[0,i] := cell;

Inc(i);
if (i>=4) then Break;

until (cds.Eof);
end;

end.

The UFRMMain.html file:

Title
============================================================= The problem is that i only see data from the first object on all the four lines and don't seen the data form the other objects. "{ "albumId": 1, "id": 1, "title": "accusamus beatae ad facilis cum similique qui sunt", "url": "https://via.placeholder.com/600/92c952", "thumbnailUrl": "https://via.placeholder.com/150/92c952" },"

How to get the data from the other objects?

Now with the html code in UFrmMain visible:

procedure TForm1.populateTable;
var
i: integer;
cell: string;
begin
i := 0;
repeat
cell := format('<ul class="space-y-1">'+

,'<li class="bg-green-200 border-2 border-black">%s</li>'+

<li class="bg-green-200 border-2 border-black">%s</li>'+
<li class="bg-green-200 border-2 border-black">%s</li>'+`
<li class="bg-green-200 border-2 border-black">%s</li>'
</ul>'+'<br>',[cds.FieldByName('title').AsString,
          cds.FieldByName('url').AsString,
          cds.FieldByName('thumbnailUrl').AsString
          ]);

``` WebTableControl1.Cells[0,i] := cell;
    Inc(i);
    if (i>=4) then Break;
  until (cds.Eof);
end;

I'm seeing CORS errors when trying to access

https://jsonplaceholder.typicode.com/photos

so, here this endpoint isn't returning any data at all?

Yes i get data but only data from the first object.

I answered I'm not getting any data.
Other than this, did you check if there is only one row in your WebClientDataSet or is your code only filling one row in the TWebTableControl?
If a problem persists, please isolate this and send a project with which we can reproduce and test this.