fix(seed): Add default values to incompleted declarations (#16704)

Closes #16696

fix(seed): Fix undefined render
This commit is contained in:
Nguyen Quoc Bao
2018-02-13 19:45:13 +08:00
committed by Stuart Taylor
parent 5c8b512168
commit 71974d6972
3 changed files with 13 additions and 15 deletions

View File

@ -543,9 +543,7 @@
" }", " }",
" render() {", " render() {",
" // complete the return statement:", " // complete the return statement:",
" return (", " return (null);",
"",
" );",
" }", " }",
"};" "};"
], ],

View File

@ -2596,11 +2596,11 @@
" }", " }",
" handleClick() {", " handleClick() {",
" this.setState({", " this.setState({",
" counter: // change code here", " counter: 0 // change code here",
" });", " });",
" }", " }",
" render() {", " render() {",
" let expression = // change code here", " let expression = null; // change code here",
" return (", " return (",
" <div>", " <div>",
" <button onClick={this.handleClick}>Play Again</button>", " <button onClick={this.handleClick}>Play Again</button>",
@ -2743,7 +2743,7 @@
" });", " });",
" }", " }",
" render() {", " render() {",
" const items = // change code here", " const items = null; // change code here",
" return (", " return (",
" <div>", " <div>",
" <textarea", " <textarea",
@ -2807,7 +2807,7 @@
"];", "];",
"", "",
"function Frameworks() {", "function Frameworks() {",
" const renderFrameworks = // change code here", " const renderFrameworks = null; // change code here",
" return (", " return (",
" <div>", " <div>",
" <h1>Popular Front End JavaScript Frameworks</h1>", " <h1>Popular Front End JavaScript Frameworks</h1>",
@ -2885,8 +2885,8 @@
" }", " }",
" }", " }",
" render() {", " render() {",
" const usersOnline = // change code here", " const usersOnline = null; // change code here",
" const renderOnline = // change code here", " const renderOnline = null; // change code here",
" return (", " return (",
" <div>", " <div>",
" <h1>Current Online Users:</h1>", " <h1>Current Online Users:</h1>",

View File

@ -676,16 +676,16 @@
"ext": "jsx", "ext": "jsx",
"name": "index", "name": "index",
"contents": [ "contents": [
"const INCREMENT = // define a constant for increment action types", "const INCREMENT = null; // define a constant for increment action types",
"const DECREMENT = // define a constant for decrement action types", "const DECREMENT = null; // define a constant for decrement action types",
"", "",
"const counterReducer = // define the counter reducer which will increment or decrement the state based on the action it receives", "const counterReducer = null; // define the counter reducer which will increment or decrement the state based on the action it receives",
"", "",
"const incAction = // define an action creator for incrementing", "const incAction = null; // define an action creator for incrementing",
"", "",
"const decAction = // define an action creator for decrementing", "const decAction = null; // define an action creator for decrementing",
"", "",
"const store = // define the Redux store here, passing in your reducers" "const store = null; // define the Redux store here, passing in your reducers"
] ]
} }
}, },