SmartClient Version: v12.0p_2019-07-11/LGPL Development Only (built 2019-07-11)
While some places (ex: List) have properties and methods marked optional, there are some classes where they are not (ex: ListGridField). I have a method that generates them with the following code:
Without marking them optional, TypeScript will complain that over 100 properties have not been defined.
Note: If you've found this thread because you're having this issue, then the way to fix it is to open smartclient.d.ts and find the relevant class/interface and add ? to the places that should be optional.
Example (field):
... turns into...
Example (method):
... turns into...
While some places (ex: List) have properties and methods marked optional, there are some classes where they are not (ex: ListGridField). I have a method that generates them with the following code:
Code:
//Code which defines dataField, title, displayWidth, and isHidden var output : isc.ListGridField = { name: dataField, title: title, canEdit: false, width: displayWidth, hidden: isHidden } return output;
Note: If you've found this thread because you're having this issue, then the way to fix it is to open smartclient.d.ts and find the relevant class/interface and add ? to the places that should be optional.
Example (field):
Code:
exportFieldWidth: boolean;
Code:
exportFieldWidth?: boolean;
Code:
sortNormalizer(recordObject: object, fieldName: string, context:ListGrid): any;
Code:
sortNormalizer?(recordObject: object, fieldName: string, context:ListGrid): any;
Comment