We are currently testing using the DocumentEditor (@syncfusion/ej2-react-documenteditor) and Spreadsheet (@syncfusion/ej2-react-documenteditor) in a Next.js app that is deployed to AWS Elastic Beanstalk. The only thing we are using these packages for is to "view" Word or Excel files (no Editing, simply read-only rendering), so really only need limited features.
The problem is that the combined package size is 368MB. We are now running into issues deploying to Elastic Beanstalk (we use CodeBuild to build and deploy the artifact which includes the node_modules folder and thus this large folder) -> and Beanstalk has a 512MB artifact limit, so deploys are now failing.
The breakdown of all related packages for syncfusion.
284 ej2-office-chart
544 ej2-file-utils
648 ej2-compression
1324 ej2-excel-export
3272 ej2-lists
3468 ej2-react-documenteditor
4348 ej2-icons
8208 ej2-buttons
8280 ej2-base
8668 ej2-react-base
9148 ej2-react-spreadsheet
9556 ej2-svg-base
10500 ej2-data
12324 ej2-splitbuttons
13296 ej2-dropdowns
13812 ej2-pdf-export
20776 ej2-popups
21184 ej2-navigations
22272 ej2-inputs
26516 ej2-charts
31696 ej2-grids
38856 ej2-spreadsheet
50228 ej2-calendars
57784 ej2-documenteditor
Are there any options or plans to release a "viewer" version of these apps that is lighter weight? I can envision where some of these packages like calendars or charts are simply not included ...
Even with document editor - I'm using the DocumentEditorContainerComponent - is that so large because it includes both? I am not using the Calendars, why does that have to be included? Is there any option for tree shaking here?
Really like how these components work, so would appreciate any insight/options here. Thanks!
Hi Keith,
Currently, We are checking this scenario and will update details by September 22, 2022.
Regards,
Dhanush Sekar
Hi Keith,
##Are there any options or plans to release a "viewer" version of these apps that is lighter weight?
Instead of using the document editor container component, you can use the document editor component to open a document in read-only mode.
We have created a sample for your reference.
https://stackblitz.com/edit/react-gqf5is-s3kyxd?file=index.html,index.js
Regards,
Dhanush Sekar
Hi Keith,
##Are there any options or plans to release a "viewer" version of these apps that is lighter weight? I can envision where some of these packages like calendars or charts are simply not included
The following minimal dependencies are necessary for the document editor:
|-- @syncfusion/ej2-react-documenteditor
|-- @syncfusion/ej2-react-base
|-- @syncfusion/ej2-base
|-- @syncfusion/ej2-build
|-- @syncfusion/ej2-buttons
|-- @syncfusion/ej2-compression
|-- @syncfusion/ej2-data
|-- @syncfusion/ej2-dropdowns
|-- @syncfusion/ej2-file-utils
|-- @syncfusion/ej2-inputs
|-- @syncfusion/ej2-lists
|-- @syncfusion/ej2-navigations
|-- @syncfusion/ej2-popups
|-- @syncfusion/ej2-splitbuttons
|-- @syncfusion/ej2-documenteditor
|-- @syncfusion/ej2-chartsDocumentation link : https://ej2.syncfusion.com/react/documentation/document-editor/getting-started/#dependencies
We'll check and let you know shortly about the spreadsheet component.
Regards,
Dhanush Sekar
Hi Keith,
The package size for spreadsheet can’t be able to reduce as every package is needed for an action to be performed. However, we can be able to make the sheet as un-editable ( read only ) mode by making the sheet as protected. We hereby shared a sample that make the sheet be in read only mode. Kindly refer to it.
Stackblitz sample: https://stackblitz.com/edit/react-g8tcfg?file=index.js
Get back to us if you need further assistance regarding
Regards,
Dhanush Sekar