Page 1 of 1

Bundle size is too big

Posted: Tue Apr 19, 2022 7:00 am
by AndreySE
Hi,

the bundle size is too big (is about 11 Mb), is any way to make it smaller?

Re: Bundle size is too big

Posted: Tue Apr 19, 2022 8:41 am
by Max Shamanov
Hello,

We are always working on reducing the bundle size. If you want, you can use pack.js files in your project, these files are smaller in size.

Thank you.

Re: Bundle size is too big

Posted: Tue Apr 19, 2022 8:59 am
by AndreySE
Thank you Max, but how to use packed version with angular?

Re: Bundle size is too big

Posted: Tue Apr 19, 2022 9:38 am
by Max Shamanov
Hello,

Unfortunatley packed version can be only used in native js.

Thank you.

Re: Bundle size is too big

Posted: Tue Apr 19, 2022 1:21 pm
by AndreySE
I did some research and found that *.pack.js is packed original script by Brotli, as all our requests are JZipped the overall difference is around 20 percents only, so it's not much.
Anyway, it's possible to use Angular imports from pack-files this way:

Code: Select all

import {
  Stimulsoft,
  StiOptions
} from 'stimulsoft-dashboards-js/Scripts/stimulsoft.dashboards.pack';
Upd: please, add corresponding ts definitions for *.pack.js files (stimulsoft.designer.pack.d.ts for ex) as IDE cannot find ts definition for pack files

Re: Bundle size is too big

Posted: Tue Apr 19, 2022 7:27 pm
by Lech Kulikowski
Hello,

Please send us your request with detailed description on support@stimulsoft.com.

Thank you.