Embed Third-Party Libraries
- 3 minutes to read
The following table lists DevExpress controls that require external client libraries to work correctly:
Extension Suite | Attached Scripts |
---|---|
Every extension | jquery-3.5.1.min.js jquery.validate.min.js (1.17) jquery.validate.unobtrusive.min.js (3.2.6) jquery.unobtrusive-ajax.min.js (3.2.4) |
jquery-3.5.1.min.js jquery-ui-1.12.1.js* cldr.min.js (0.4.3) cldr.event.min.js (0.4.3) cldr.supplemental.min.js (0.4.3) cldr.unresolved.js (0.4.3) globalize.js (1.0.1) globalize.message.min.js (1.0.1) globalize.number.min.js (1.0.1) globalize.currency.min.js (1.0.0) globalize.date.min.js (1.0.1) knockout-3.4.0.js ace.js ext-language_tools.js theme-ambiance.js theme-dreamweaver.js | |
DashboardViewer | jquery-3.5.1.min.js cldr.min.js (0.4.3) cldr.event.min.js (0.4.3) cldr.supplemental.min.js (0.4.3) cldr.unresolved.js (0.4.3) globalize.js (1.0.1) globalize.message.min.js (1.0.1) globalize.number.min.js (1.0.1) globalize.currency.min.js (1.0.0) globalize.date.min.js (1.0.1) |
jquery-3.5.1.min.js jquery-ui-1.12.1.js* cldr.min.js (0.4.3) cldr.event.min.js (0.4.3) cldr.supplemental.min.js (0.4.3) cldr.unresolved.js (0.4.3) globalize.js (1.0.1) globalize.message.min.js (1.0.1) globalize.number.min.js (1.0.1) globalize.currency.min.js (1.0.0) globalize.date.min.js (1.0.1) knockout-3.4.0.js ace.js ext-language_tools.js theme-ambiance.js theme-dreamweaver.js | |
jquery-3.5.1.min.js jquery-ui-1.12.1.js* cldr.min.js (0.4.3) cldr.event.min.js (0.4.3) cldr.supplemental.min.js (0.4.3) cldr.unresolved.js (0.4.3) globalize.js (1.0.1) globalize.message.min.js (1.0.1) globalize.number.min.js (1.0.1) globalize.currency.min.js (1.0.0) globalize.date.min.js (1.0.1) knockout-3.4.0.js | |
jquery-3.5.1.min.js jquery-ui-1.12.1.js* cldr.min.js (0.4.3) cldr.event.min.js (0.4.3) cldr.supplemental.min.js (0.4.3) cldr.unresolved.js (0.4.3) globalize.js (1.0.1) globalize.message.min.js (1.0.1) globalize.number.min.js (1.0.1) globalize.currency.min.js (1.0.0) globalize.date.min.js (1.0.1) knockout-3.4.0.js |
*DevExpress controls require the following parts of the jQuery UI Library:
- core.js
- draggable.js
- mouse.js
- resizable.js
- selectable.js
- widget.js
Important
In addition to the third-party libraries, DevExpress controls listed in the table above use DevExtreme client libraries. Refer to the “Integration with 3rd-Party Libraries and Frameworks” section in the Introduction to DevExtreme topic for more information.
Declaration
Add a DevExpress control to a project to register the “resources” section in the application’s Web.config file.
<configuration>
<configSections>
<sectionGroup name="devExpress">
<!-- ... -->
<section name="resources" type="DevExpress.Web.ResourcesConfigurationSection, DevExpress.Web.v19.1, Version=19.1.16.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" requirePermission="false" />
</sectionGroup>
</configSections>
<!-- ... -->
</configuration>
Add the external libraries or enable the control to load them automatically to the “resources” section in the web.config file to ensure the control works correctly.
Note
The “resources” section allows you to load only client resources required by a specific web control.
The code snippet below allows you to register the following resources:
“DevExtreme” - adds the DevExtreme suite’s client sources.
“ThirdParty” - adds references to external libraries.
<devExpress>
<!-- ... -->
<resources>
<add type="ThirdParty" />
<add type="DevExtreme" />
</resources>
</devExpress>
Register client scripts automatically
DevExpress automatically registers the related client libraries when you use the DevExpress Template Gallery to add a DevExpress control to a web page.
Note
Note that the DevExpress Template Gallery provides the “Check References To External Scripts” check box that allows you not to generate the “resources” section in the Web.config file.
Register client scripts manually
Register only DevExtreme libraries
DevExpress automatically loads DevExtreme libraries without the third-party libraries in the following cases:
The Web.config file does not contain the “resources” section.
DevExpress does not add the “resources” section in the web.config file when you load a DevExpress web control to a project and do not use the DevExpress Template Gallery.
If DevExpress does not register DevExtreme libraries automatically, use the following code snippet to register them in the Web.config file.
<resources>
<add type="DevExtreme" />
</resources>
Register only third-party libraries
Use the following code to register the third-party libraries (without the DevExtreme libraries) in the web.config file:
<resources>
<add type="ThirdParty" />
</resources>
Note that DevExpress Reports, Dashboards and Bootstrap control suites use DevExtreme controls and require their scripts on a page. In this case, register the DevExtreme scripts either in the Web.config file…
<resources>
<add type="DevExtreme" />
</resources>
… or load them to the page in the following order:
Third-party libraries.
DevExtreme.
Specific control scripts.
Detach external client libraries
Declare an empty “resources” section not to load external client scripts (including DevExtreme libraries). You should attach all the resources to a web page.
<resources>
</resources>
Related Configuration Section
DevExpress configuration section