Speed up Episerver Forms in View mode

Use site’s jQuery if possible

By default, EpiForm needs jQuery 1.7.2 to run its processing in View mode (interaction, steps navigation, validation, save/load data to localStorage, …).

Why choose version 1.7.2? Because it is align with what they use in AlloyMVC template. Actually, EpiForm can work with newer jQuery version very well. I haven’t found any problem with jQuery 1.9, 1.12

If you website already has jQuery 1.7.2+, you can turn EpiForm’s jQuery off, to save some payload and network transmission for your visitor. EpiForm will use the site’s jQuery instance without any problem.

Go to your site location, edit file wwwroot/modules/_protected/EPiServer.Forms/Forms.config

Change injectFormOwnJQuery to false

Turn off debug clientResources flag

EpiForm is new and hot, so a lot of developer want to dig it deeper, dissemble the DLL, open up the JS API. From version 1.1, you can turn <clientResources debug=”true” /> in your web.config (inside the episerver.framework element), so EpiForm will load the normal JS code (with a lot of comments and clear function names).

But, please remember to turn it off, so EpiForm will load the minified version for ViewMode rendering.

Like what you read? Give lockevn a round of applause.

From a quick cheer to a standing ovation, clap to show how much you enjoyed this story.