-
-
Save ypcode/991fa9b892fb1930836bbaef3f39bd7d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { ServiceKey } from "@microsoft/sp-core-library"; | |
export interface IGreetingsService { | |
sayHello(who: string) : string; | |
} | |
export class GreetingsService implements IGreetingsService { | |
public sayHello(who: string) : string { | |
return `Hello ${who}`; | |
} | |
} | |
export const GreetingsServiceKey = ServiceKey.create<IGreetingsService>( | |
'YPCODE:GreetingsService', | |
GreetingsService | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment