Currently, I did like this in order to include a .js file, but every time I built I got a new hash generated, so I need to update after that. any ways I can do this better? thanks
my pages are store in www/page.(html.js.css)
// included frappe and erpnext js, abit hack code here
frappe.require([
'/assets/frappe/dist/js/libs.bundle.7AKUR6TI.js',
"/assets/frappe/dist/js/desk.bundle.WBRFCWUB.js",
"/assets/frappe/dist/js/form.bundle.N2BLMFYM.js",
"/assets/erpnext/dist/js/erpnext.bundle.B5EPUHKI.js"]
);
console.log('js called view pos');
$("#target").click(function () {
console.log("Handler for .click() called by jquery");
});
Those bundles are all loaded globally and shouldn’t need to be required at runtime. Are you facing a problem calling api functions without the require statement?