removeAt method
Removes the page at the given specified index.
//Load an exisiting PDF document.
PdfDocument document = PdfDocument.fromBase64String(pdfData);
//Remove the page at index 0.
document.pages.removeAt(0);
//Save and dispose document.
List<int> bytes = await document.save();
document.dispose();
Implementation
void removeAt(int index) {
if (index > -1 && index < count) {
final PdfPage? page = _returnValue(index);
_removePage(page, index);
}
}