stricklandrbls commented on code in PR #841:
URL: https://github.com/apache/daffodil-vscode/pull/841#discussion_r1327675673


##########
src/dataEditor/dataEditorClient.ts:
##########
@@ -94,8 +96,19 @@ const OMEGA_EDIT_MIN_PORT: number = 1024
 // file-scoped types
 // 
*****************************************************************************
 
+class ServerInfo implements IServerInfo {
+  serverHostname: string = 'unknown' // hostname

Review Comment:
   I've been reading a bit on *stringly-typed* objects in TypeScript and it 
seems to be best to avoid them
   > See **Item 33: Prefer More Precise Alternatives to String Types** in 
*Effective TypeScript* by Don Vanderkam
   
   Maybe `serverHostname: string` could be `serverHostname: Hostname` where 
<code>type Hostname = "unknown" | "localhost" | 
\`${number}.${number}.${number}.${number}` </code>. Likewise for other 
*stringly-typed* variables.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to