2017-02-04 76 views
0

您好,我想知道为什么它的控制台未知道具的警告作出反应JS`iconClassNameRight`

Warning: Unknown prop `iconCLassNameRight` on <div> tag. Remove this prop from the element. For details, see link fb me 
    in div (created by Paper) 
    in Paper (created by AppBar) 
    in AppBar (created by App) 
    in div (created by App) 
    in MuiThemeProvider (created by App) 
    in App 

的就扔一个警告,我做这个工作的代码是meteorjs和材料UI

import React, { Component } from 'react'; 
import MuiThemeProvider from 'material-ui/styles/MuiThemeProvider'; 
import RaisedButton from 'material-ui/RaisedButton'; 
import AppBar from 'material-ui/AppBar'; 

import Player from './Player.jsx'; 
import TeamList from './Team-list.jsx'; 
import TeamStats from './Team-stats.jsx'; 

export default class App extends Component { 
    render(){ 
    return (
     <MuiThemeProvider> 
     <div className="container"> 
      <AppBar 
      title="Soccer Application" iconCLassNameRight="muidocs-icon-navigation-expand-more" showMenuIconButton={false} /> 
      <div className="row"> 
       <div className="col s12 m7"> <Player /> </div> 
       <div className="col s12 m5"> <TeamStats /> </div> 
       <div className="col s12 m5"> <TeamList /> </div> 
      </div> 
      </div> 

     </MuiThemeProvider> 
    ) 
    } 
    } 

我想知道为什么这是抛出一个错误。感兴趣的行位于appbar组件iconClassNameRight属性中。任何帮助将大大appreaciated。谢谢。

+1

的错误是在纸张的组件,而是your're展示应用。粘贴纸,以及我们可以看到道具从一个流向另一个(propTypes也会有帮助)。 – CharlieBrown

回答

2

React中的道具区分大小写。

尝试更换iconCLassNameRight(大写L)到iconClassNameRight(小写L)