HOT-FIX. Добавлены методы создания компонентов и нод внутри компонентов
This commit is contained in:
@ -2,7 +2,6 @@ import Component from '../component/index';
|
||||
import routeService from '../../services/RouteService';
|
||||
|
||||
import './MainMenu.css';
|
||||
import {createElement} from '../../utils/elementUtils';
|
||||
import {EVENTS} from '../../consts';
|
||||
import tokenApi from '../../api/TokenAPI';
|
||||
|
||||
@ -69,14 +68,14 @@ class MainMenu extends Component {
|
||||
|
||||
render = () => {
|
||||
this.menuItems = NAV_MENU.map(({url, title, className = ''}) => {
|
||||
const li = createElement({
|
||||
const li = this.createElement({
|
||||
tagName: 'li',
|
||||
parentNode: this.buttonsContainer,
|
||||
options: {
|
||||
className: `nav-item ${className}`,
|
||||
},
|
||||
});
|
||||
const link = createElement({
|
||||
const link = this.createElement({
|
||||
tagName: 'a',
|
||||
parentNode: li,
|
||||
options: {
|
||||
|
||||
Reference in New Issue
Block a user