diff --git a/src/App.js b/src/App.js index a650aee..57fe441 100644 --- a/src/App.js +++ b/src/App.js @@ -14,16 +14,35 @@ class App extends Component { }; static childContextTypes = { - user: PropTypes.string + user: PropTypes.string, + lang: PropTypes.string, + vocab: PropTypes.object } state = { - username: '' + username: '', + language: 'en', + vocabulary: { + 'counter':{ + 'en':'counter', + 'ru':'счетчик' + }, + 'hide comments':{ + 'en':'hide comments', + 'ru':'скрыть комментарии' + }, + 'Articles page':{ + 'en':'Articles page', + 'ru':'Страница статей' + } + } } getChildContext() { return { - user: this.state.username + user: this.state.username, + lang: this.state.language, + vocab: this.state.vocabulary } } @@ -31,9 +50,14 @@ class App extends Component { console.log('---', 'rendering App') return (