loadJS Method

Summary

Helper method to dynamically load a JS file and add it to the script section of the current document.

Syntax
TypeScript
JavaScript
loadJS = function( 
   fileName, 
   callback 
) 
static loadJS( 
   fileName: string, 
   callback: Function 
): void; 

Parameters

fileName

Path to the JS file to load.

callback

Function to call when the JS file has been loaded.

Remarks

This method works by enumerating the script tags in the current document for a matching fileName, if the item is not found then it is inserted in the document. If the item is found, then nothing is done.

Requirements
Target Platforms
Help Version 21.0.2021.6.30
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.

Leadtools Assembly
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.