Ticket #6101 (assigned defect)

Opened 5 months ago

Last modified 5 months ago

don't force include of everything in dijit/_base

Reported by: bill Owned by: bill
Priority: normal Milestone: 2.0
Component: Dijit Version: 1.0
Severity: normal Keywords:
Cc:

Description

_Widget.js dojo.require()'s a bunch of code that it doesn't use (focus, wai, etc.) just in case subclasses like Button want to use that code. This is detrimental to making small builds for iPhone, etc. Modify Widget.js and other resources to only require() what they are actually using.

Developers can still get all the code in dijit/base by including dijit.js.

Given that this is sort-of an API change (although it will only impact developers who write custom widgets), won't implement until 2.0, but can implement interim workaround in code providing custom build option to only require() the files that are being used.

//>>excludeStart("dijitBaseExclude", kwArgs.customDijitBase == "true");
dojo.require( "dijit._base" );
//>>excludeEnd("dijitBaseExclude");

Change History

Changed 5 months ago by bill

  • status changed from new to assigned
  • owner set to bill

Changed 5 months ago by bill

(In [12931]) Provide build flag so Widget.js doesn't pull in all of dijit._base. The is an intermim solution for making lightweight builds (especially for custom widgets) that don't use all the code in dijit/base. Refs #6101. !strict

Note: See TracTickets for help on using tickets.