Change getDefaultProps to static and remove warning

Summary:
When trying sample code from the _Working with Scenes_ area of this page I see a warning and the example did not appear to work as expected.  To fix this I updated the code to static so others following along will not see a warning about using a static property to define defaultProps.   Also included is a screen capture of the warning message.

![react-native-warning-defaultprops](https://cloud.githubusercontent.com/assets/1053650/17271580/9d0e85fc-564d-11e6-9c58-f73ef708aade.png)
Closes https://github.com/facebook/react-native/pull/9108

Differential Revision: D3647366

fbshipit-source-id: 93b152756e6351614caf4ae1d5f45bac893fdf7b
This commit is contained in:
gregjacobson 2016-07-30 16:59:05 -07:00 коммит произвёл Facebook Github Bot
Родитель e8b508144f
Коммит db35324610
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -31,7 +31,7 @@ import React, { Component } from 'react';
import { View, Text } from 'react-native';
export default class MyScene extends Component {
getDefaultProps() {
static get defaultProps() {
return {
title: 'MyScene'
};