javascript - Using a custom Kendo-UI build with JSPM -
i'm using kendoui in aurelia application. far, using grid control , autocomplete control.
attempting import kendo objects through es6 (using system.js , import
statement) has worked kendo.all.min.js, exports kendo
object of namespaces.
my import statement kendo.all.min.js follows:
import * kendo 'kendo';
i can use var datasource = new kendo.data.datasource()
. (i've set config.js point 'kendo' correct file using meta section.)
kendo.all.min.js quite large , of functionality unnecessary. created kendo.custom.min.js file components we're using. however, attempting import kendo through es6 no longer works. no longer receive usable properties on imported object.
how can have kendo custom build work es6 imports?
i found answer - must specified in config.js.
because kendo amd package default, jspm (and other loaders requirejs) needs know exports. had in jspm configuration:
meta: { "vendor/kendo/kendo.custom.min.js": { "deps": [ "github:components/jquery@2.1.4" ], } },
i had change adding line:
meta: { "vendor/kendo/kendo.custom.min.js": { "deps": [ "github:components/jquery@2.1.4" ], "exports": "kendo" } },
...and worked.i'm seeing kendo objects in export.
Comments
Post a Comment