How do I make one class Server visible inside another class Database in Typescript? When I try to create an instance of var theServer = new Server(); inside the Database class I get the following error:

ReferenceError: Server is not defined
有帮助吗?

解决方案

You need to have script tags in your page for both Database.js and Server.js.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top