2017-02-04 80 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)