kendoui and webpack how to load jszip

3 posts, 1 answers
  1. Enrico
    Enrico avatar
    54 posts
    Member since:
    Jun 2013

    Posted 21 Aug Link to this post

    Hi,

    I've installed kendo (latest buil) using npm with my pro license.

    I'm able to make it work using webpack, but I could not do the same with jszip which is required for export.

     

    Any suggestion?

    Thanks!

  2. Enrico
    Enrico avatar
    54 posts
    Member since:
    Jun 2013

    Posted 21 Aug Link to this post

    Sorry for this auto-answer, but I'm still new to webpack and I just came across a possible solution.

    Since kendo is referencing JSZip as global, you have to use ProvidePlugin as following:

    config.plugins.push(new webpack.ProvidePlugin({
      'JSZip': 'jszip',
      'window.JSZip': 'jszip' // this doesn't expose JSZip property for window, but exposes it to every module
    }));

     

    If you have a better way please let me know!

     

    Thanks

  3. Kendo UI is VS 2017 Ready
  4. Answer
    Petyo
    Admin
    Petyo avatar
    2439 posts

    Posted 24 Aug Link to this post

    Hello,

    that's a good approach, actually. We do the same thing for our commonjs module packaging.

    Regards,
    Petyo
    Telerik by Progress
     
    Get started with Kendo UI in days. Online training courses help you quickly implement components into your apps.
     
Back to Top