首页 > TAG信息列表 > ComentA
React父子组件传值
一、父组件向子组件传值 1.父组件中定义要传的值 import React, { Component } from "react" import "./assets/css/app.css" // 引入组件A import ComentA from "./components/ComentA" class App extends Component { constructor(props) { super(props)React父子组件传值
一、父组件向子组件传值 1.父组件中定义要传的值 import React, { Component } from "react" import "./assets/css/app.css" // 引入组件A import ComentA from "./components/ComentA" class App extends Component { constructor(props) { super(props)