Skip to content

react app bundle size issue #169

Open
@veresk17

Description

@veresk17

Expected behavior

Build size should be reasonable for react app.

Current behavior

Using react/typescript template for task pane app. Npm run build produce large taskpane.js file

The following message is show in the console

WARNING in entrypoint size limit: The following entrypoint(s) combined asset size exceeds the recommended limit (244 KiB). This can impact web performance.
Entrypoints:
vendor (402 KiB)
vendor.js
taskpane (13.6 MiB)
taskpane.js

Webpack configuration may be incorrect.
It seems that it was at least partly fixed inside the template repo https://github.com/OfficeDev/Office-Addin-TaskPane-React?tab=readme-ov-file
but for some reason generator office uses older version of the template.

Steps to Reproduce

Please provide detailed steps for reproducing the issue.

  1. create react task pane app using generator (options: Office Add-in Task Pane project using React framework, Typescript)
  2. install dependancies
  3. build the app (npm run build)
  4. check file sizes

Context

  • Operating System: macOS
  • Node version: 22.11.0
  • Tool version: 2.0.3

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions