Spreadsheet import
Paste a CSV and the files/CSV resource parses it into rows on the server.
Read the docs →.phlo
// upload a CSV; %payload makes it a file you move into place, then parse
route async POST import parse {
%payload->csv?->move(data.'upload.csv')
$csv = %CSV('upload')
return apply(inner: ['#out' => $this->table($csv->objData)])
}
csvpeople.csv3 rows
| name | role | city |
|---|---|---|
| Ada | Engineer | London |
| Alan | Mathematician | Manchester |
| Grace | Admiral | New York |
