How to disable js minify at nop4.5

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
один год назад
paravan3010 wrote:
Hi chashikNop,
thanks for your reply! Unfortunatelly this didn't help me either. All JS files are still requested and loaded minified.
I also believe this issue deserves more attention from the nopCommerce team regardless of whether the workaround works.


I will have a more attentive look.
один год назад
paravan3010 wrote:
Hi chashikNop,
thanks for your reply! Unfortunatelly this didn't help me either. All JS files are still requested and loaded minified.
I also believe this issue deserves more attention from the nopCommerce team regardless of whether the workaround works.

Please, try this in your appsettings.json

"WebOptimizer": {
    "EnableJavaScriptBundling": false,
...
  }


var AjaxCart = {
    loadWaiting: false,
    usepopupnotifications: false,
    topcartselector: '',
    topwishlistselector: '',
    flyoutcartselector: '',
    localized_data: false,

    init: function (usepopupnotifications, topcartselector, topwishlistselector, flyoutcartselector, localized_data) {
        this.loadWaiting = false;
        this.usepopupnotifications = usepopupnotifications;
        this.topcartselector = topcartselector;
        this.topwishlistselector = topwishlistselector;
        this.flyoutcartselector = flyoutcartselector;
        this.localized_data = localized_data;
    },

    setLoadWaiting: function (display) {
        displayAjaxLoading(display);
        this


working like a charm)

I've missed 4.6.1 update. Thanks the nopCommerce team that they made this setting. It made workarounds unnecessary.
один год назад
chashikNop wrote:
...P. S. for moderators: can not attach images to a post...

I've just answered similar question here
https://www.nopcommerce.com/en/boards/topic/96152/image-host#303440
один год назад
I've already tried EnableJavaScriptBundling in appSettings.json. It prevents bundling but not minification of separate JS files.
I don't understand the second code block with AjaxCart. Seems the same as in nop 4.60.
Can you please provide a link to an issue or release note, where this was mentioned in 4.6.1? I didn't find it on GitHub or in relase note.
один год назад
paravan3010 wrote:
I've already tried EnableJavaScriptBundling in appSettings.json. It prevents bundling but not minification of separate JS files.
I don't understand the second code block with AjaxCart. Seems the same as in nop 4.60.
Can you please provide a link to an issue or release note, where this was mentioned in 4.6.1? I didn't find it on GitHub or in relase note.


The AjaxCart block is the example of unbundled and pure JS code which I've got after changing the setting.

Jquery and some other scripts go minified out-of-box. You can get unminified versions from the developers CDN.

It is sad that can not attach screens from my OneDrive account (
один год назад
paravan3010 wrote:
I've already tried EnableJavaScriptBundling in appSettings.json. It prevents bundling but not minification of separate JS files.
I don't understand the second code block with AjaxCart. Seems the same as in nop 4.60.
Can you please provide a link to an issue or release note, where this was mentioned in 4.6.1? I didn't find it on GitHub or in relase note.


https://1drv.ms/u/s!AghLRh3xrCQxgc4dFmx6ChGVKyBc8Q?e=xEw0gl

https://1drv.ms/u/s!AghLRh3xrCQxgc4ekOPsRYK7HaNwiA?e=cnEl1c

Using Microsoft services became not easy these days. Azure crashes constantly and now I have the same url for 2 different files.
Should work now.
один год назад
Thank you for your patience. As it's working for you, it seems I'm overlooking something.
I've got my own non-minified JS file in ...\Presentation\Nop.Web\Plugins\PLUGIN_NAME\Content\js\JS_FILE.js.
It's added to my view:
NopHtml.AppendScriptParts(Nop.Web.Framework.UI.ResourceLocation.Footer, "~/Plugins/PLUGIN_NAME/Content/js/JS_FILE.js", excludeFromBundle: true);

EnableJavaScriptBundling is disabled in appsettings.json. It never enters the block you are debugging. But GET requests still look like this and get minified versions of the files:
https://localhost:64838/Plugins/PLUGIN_NAME/Content/js/JS_FILE.js?v=pHFkxGe7GRzpehXSwt7v8tLKZKM
один год назад
paravan3010 wrote:
Thank you for your patience. As it's working for you, it seems I'm overlooking something.
I've got my own non-minified JS file in ...\Presentation\Nop.Web\Plugins\PLUGIN_NAME\Content\js\JS_FILE.js.
It's added to my view:
NopHtml.AppendScriptParts(Nop.Web.Framework.UI.ResourceLocation.Footer, "~/Plugins/PLUGIN_NAME/Content/js/JS_FILE.js", excludeFromBundle: true);

EnableJavaScriptBundling is disabled in appsettings.json. It never enters the block you are debugging. But GET requests still look like this and get minified versions of the files:
https://localhost:64838/Plugins/PLUGIN_NAME/Content/js/JS_FILE.js?v=pHFkxGe7GRzpehXSwt7v8tLKZKM


Best wishes in debugging the plugin then. Hope you find the reason soon.
I used the raw 4.6.1 installation - the setting works.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.