added types to utils

This commit is contained in:
Zack Hoherchak 2022-03-04 17:41:02 -05:00
commit 3174409e20

View file

@ -1,7 +1,7 @@
class Utils { class Utils {
/** /**
* Returns the value from a form using the form controls name property * Returns the value from a form using the form controls name property
* @param {*} form * @param {Element | string} form
* @returns * @returns
*/ */
static getFormValue(form) { static getFormValue(form) {
@ -35,7 +35,7 @@ class Utils {
/** /**
* Sets the value of form controls using their name attribute and the jsn object key * Sets the value of form controls using their name attribute and the jsn object key
* @param {*} jsn * @param {*} jsn
* @param {*} form * @param {Element | string} form
*/ */
static setFormValue(jsn, form) { static setFormValue(jsn, form) {
if (typeof form === 'string') { if (typeof form === 'string') {
@ -68,7 +68,7 @@ class Utils {
/** /**
* This provides a slight delay before processing rapid events * This provides a slight delay before processing rapid events
* @param {*} wait - delay before processing function (recommended time 150ms) * @param {number} wait - delay before processing function (recommended time 150ms)
* @param {function} fn * @param {function} fn
* @returns * @returns
*/ */