Maybe this is a stupid question but can not find anything, help me.
I'm trying TS, and I happened to test an interface
interface HelloWorldTS {
name : string;
}
within this code.
class Startup {
public static main(): number {
console.log('Hello World');
return 0;
}
}
Startup.main();
interface HelloWorldTS {
name : string;
}
class Startup {
public static main(): number {
console.log('Hello World');
TSInterface : HelloWorldTS = { name: "hello"};
return 0;
}
}
Startup.main();
but I make a error: cannot find name "HelloWorldTS", in this line TSInterface : HelloWorldTS = { name: "hello"};
My question is, if possible use an interface from a static method, and if so, what is my mistake. sorry for my bad English I hope you understand what I want to ask