@Test
    public void listFill() {
        // Template note: Use {} to represent variables. If the template contains "{", "}" as special characters, use "\{", "\}" instead.
        // When filling a list, note that {.} in the template indicates a list.
        String templateFileName =
            TestFileUtil.getPath() + "demo" + File.separator + "fill" + File.separator + "list.xlsx";

        // Option 1: Load all data into memory at once and fill
        String fileName = TestFileUtil.getPath() + "listFill" + System.currentTimeMillis() + ".xlsx";
        // This will fill the first sheet, and the file stream will be closed automatically.
        EasyExcel.write(fileName).withTemplate(templateFileName).sheet().doFill(data());

        // Option 2: Fill in multiple passes using file caching (saves memory)
        fileName = TestFileUtil.getPath() + "listFill" + System.currentTimeMillis() + ".xlsx";
        ExcelWriter excelWriter = EasyExcel.write(fileName).withTemplate(templateFileName).build();
        WriteSheet writeSheet = EasyExcel.writerSheet().build();
        excelWriter.fill(data(), writeSheet);
        excelWriter.fill(data(), writeSheet);
        // Do not forget to close the stream
        excelWriter.finish();
    }
Example of filling a list of data.

@since 2.1.1
fastexcel-test/src/test/java/cn/idev/excel/test/temp/fill/FillTempTest.java