Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

7
  • 1
    Can you create small demo on stackblitz.com So I can take a detailed look. My guess is ngOnInit is called before the external dependencies are are loaded. Commented Aug 20, 2019 at 9:03
  • 1
    Can you show the result of this log - console.log('color of g5: ' + this.game.square_color('g5')); Commented Aug 20, 2019 at 9:07
  • 1
    @alt255: I'm gonna look stackblitz and create a demo but the code is also available at github.com/pbaioni/ChessboardNg, branch Develop, commit "stackoverflow post" Commented Aug 20, 2019 at 9:19
  • 1
    @Todarmal here's the result of the log : 'color of g5: dark' Commented Aug 20, 2019 at 10:01
  • Can you try initializing the game and board in the constructor. Please let me know if the error comes. Commented Aug 20, 2019 at 10:08