当前位置: 首页 > news >正文

如何做适合手机访问的网站网站备案费一般是多少

如何做适合手机访问的网站,网站备案费一般是多少,设计公司企业标志,西安 餐饮 网站建设自定义组件的时候往往需要传 children#xff0c;由于写法比较多样#xff0c;我就总结了一下。 方案列表 1. 类组件1.1 类组件#xff0c;不使用解构1.2 类组件#xff0c;使用解构 2. 函数组件2.1 函数组件#xff0c;不使用解构2.2 函数组件#xff0c;外部解构2.3 函…自定义组件的时候往往需要传 children由于写法比较多样我就总结了一下。 方案列表 1. 类组件1.1 类组件不使用解构1.2 类组件使用解构 2. 函数组件2.1 函数组件不使用解构2.2 函数组件外部解构2.3 函数组件内部解构 3. 普通函数3.1 普通函数内部解构3.2 普通函数外部解构3.3 普通函数外部解构不使用自定义Type3.4 普通函数不使用解构不使用自定义Type 调用及展示 要自定义的组件是这样的 其中包含一个 title 和一个 children。 定义一个后面要用到的 Props: /** 定义属性对象* - title: 标题* - children: 子组件*/ type Props {title: string;children?: React.ReactNode; };1. 类组件 1.1 类组件不使用解构 class ClassComponent1 extends ComponentProps {render(): ReactNode {return (div style{{ backgroundColor: red }}h2{this.props.title}/h2{this.props.children}/div);} }1.2 类组件使用解构 class ClassComponent2 extends ComponentProps {render(): ReactNode {// 解构赋值const { title, children } this.props;return (div style{{ backgroundColor: red }}h2{title}/h2{children}/div);} }2. 函数组件 2.1 函数组件不使用解构 const FunctionComponent1: React.FCProps (props) {return (div style{{ backgroundColor: orange }}h2{props.title}/h2{props.children}/div); };2.2 函数组件外部解构 const FunctionComponent2: React.FCProps ({ title, children }) {return (div style{{ backgroundColor: orange }}h2{title}/h2{children}/div); };2.3 函数组件内部解构 const FunctionComponent3: React.FCProps (props) {// 解构赋值const { title, children } props;return (div style{{ backgroundColor: orange }}h2{title}/h2{children}/div); };3. 普通函数 3.1 普通函数内部解构 function NormalFunction1(props: Props) {// 解构赋值const { title, children } props;return (div style{{ backgroundColor: yellow }}h2{title}/h2{children}/div); }3.2 普通函数外部解构 function NormalFunction2({ title, children }: Props) {return (div style{{ backgroundColor: yellow }}h2{title}/h2{children}/div); }3.3 普通函数外部解构不使用自定义Type function NormalFunction3({title,children, }: {title: string;children?: React.ReactNode; }) {return (div style{{ backgroundColor: yellow }}h2{title}/h2{children}/div); }3.4 普通函数不使用解构不使用自定义Type function NormalFunction4(props: { title: string; children?: React.ReactNode }) {return (div style{{ backgroundColor: yellow }}h2{props.title}/h2{props.children}/div); }调用及展示 export default class ChildrenPage extends Component {render() {return (div style{{ padding: 20px }}h1组件传children/h1ClassComponent1 title类组件不使用解构p这里是children/p/ClassComponent1ClassComponent2 title类组件使用解构p这里是children/p/ClassComponent2FunctionComponent1 title函数组件不使用解构p这是里children/p/FunctionComponent1FunctionComponent2 title函数组件外部解构p这是里children/p/FunctionComponent2FunctionComponent3 title函数组件内部解构p这是里children/p/FunctionComponent3NormalFunction1 title普通函数内部解构p这里是children/p/NormalFunction1NormalFunction2 title普通函数外部解构p这里是children/p/NormalFunction2NormalFunction3 title普通函数外部解构不使用自定义Typep这里是children/p/NormalFunction3NormalFunction4 title普通函数不使用解构不使用自定义Typep这里是children/p/NormalFunction4/div);} }
http://www.w-s-a.com/news/59734/

相关文章:

  • 移动手机网站建设如何做网站地图视频
  • 手工业网站怎么做成都酒吧设计公司
  • .net 网站生成安装文件目录重庆网站建设沛宣网络
  • 怎么做钓鱼网站吗百度免费域名注册网站
  • 如何给网站做外部优化今年国内重大新闻
  • 有没有做生物科技相关的网站弄一个app大概多少钱
  • 五金加工东莞网站建设怎么做网页跳转
  • 淄博网站优化价格wordpress没有小工具
  • 自己搭建服务器做视频网站wordpress发布文章 发布
  • php仿博客园网站阅读分享网站模板
  • 网站宣传的劣势域名注册长沙有限公司
  • 怎样联系自己建设网站企业怎样做好网站建设
  • 网站制作需求分析电商网站建设浩森宇特
  • 淄博网站建设招聘摄影网站建设的论文
  • 怎么把凡科网里做的网站保存成文件网站建设研究的意义
  • 服务器2003怎么做网站网站建设服务器的配置
  • 高校网站建设方案网站推广软件下载安装免费
  • 重庆没建网站的企业网站开发软件 连接SQL数据库
  • 百度申诉网站沉默是金
  • 如何自己建网站wordpress图片延时加载
  • 甘肃省住房和城乡建设厅注册中心网站千博企业网站管理系统2013
  • 西餐厅网站模板seo搜索引擎优化ppt
  • 什么做的网站吗wordpress注册可见插件
  • 献县做网站价格可以提升自己的网站
  • 如何修改网站title建设网站只能是公司
  • 网站推广效果怎么样建设工程公司组织架构图
  • 成都制作网站价格表网站安全证书过期怎么办
  • 高校图书馆网站的建设方案湖南常德市
  • 房地产怎么做网站推广wordpress插件汉化下载
  • 一般pr做视频过程那个网站有无锡网络公司平台