Hello all, I am using the following code to test out spine web player on my react project
var spineParent = new SpinePlayer("player-container", {
jsonUrl: "",
atlasUrl: "",
animation: 'jump',
premultipliedAlpha: true,
backgroundColor: '#cccccc',
viewport: {
debugRender: true,
showControls: true,

export default function SpineViewer() {
return (
<div id="player-container" style="width: 640px; height: 480px;"></div>;
However, I am getting a error of Player.ts:227 Uncaught Error: SpinePlayer parent not found: player-container
at new SpinePlayer. I am using npm to install all the packages. Any help is greatly appreciated :grinteeth:
  • Mesajlar: 1


I'm not familiar with React, but when you call new SpinePlayer, it looks for the element with the specified ID, player-container. You'll need your DIV in the document before you call new SpinePlayer.
Kullanıcı avatarı

  • Mesajlar: 12219

Dön Runtimes