initialZoomLevel property Null safety

double initialZoomLevel

Represents the initial zoom level to be applied when the SfPdfViewer widget is loaded.

Defaults to 1.0

This example demonstrates how to set the initial zoom level to the SfPdfViewer.

class MyAppState extends State<MyApp>{

late PdfViewerController _pdfViewerController;

 void initState(){
   _pdfViewerController = PdfViewerController();

 Widget build(BuildContext context) {
   return MaterialApp(
     home: Scaffold(
       appBar: AppBar(
          title: Text('Syncfusion Flutter PdfViewer'),
       body: SfPdfViewer.asset(
         controller: _pdfViewerController,
         initialZoomLevel: 2.0,


final double initialZoomLevel;