diff --git a/src/components/stage.js b/src/components/stage.js index 9af7f5a02dc73e07a65124a9b78c14ac3c8156b8..2f872371bcec4cf1c9f478e48a829506601aaf45 100644 --- a/src/components/stage.js +++ b/src/components/stage.js @@ -6,17 +6,23 @@ class Stage extends React.Component { <canvas className="scratch-stage" ref={this.props.stageRef} + width={this.props.width} + height={this.props.height} /> ); } } Stage.propTypes = { - stageRef: React.PropTypes.func + stageRef: React.PropTypes.func, + width: React.PropTypes.number, + height: React.PropTypes.number }; Stage.defaultProps = { - stageRef: function () {} + stageRef: function () {}, + width: 480, + height: 360 }; module.exports = Stage;