Skip to content

Remove entry-points from XML #4

@pH4Lk0n

Description

@pH4Lk0n

I'm trying to use this library along with SmartGWT but core.js included in this version is making a mess. Newer versions works fine.
But unfortunately core.js is hard-coded in library and I cannot load without it because of resources used in onModuleLoad(). So everything brakes down when I just add inherits in xml.
So I've a suggestion.
Remove entry-points from XMLs. They are not actually execute and they only enforce inclusion off all TextResources. You still need to manually call injectJs methods so there is no benefit of this.
So when I just add inherits to my project XML code is automatically larger of 1MB (AmCharts base code) even if it's not called. When you remove those entry-points TextResources (ex.core.js) are only included to compiled code when they are actually used.
Other benefits:

  • You can then manually load those libraries in different way on demand when they are actually needed - it's very useful in large applications.
  • You can load core.js and others from html script tags and upgrade those files not needed to wait until library gets upgraded.

I would also move them to another module to be more clear about it.
Best regards

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions