摘要:
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>条件渲染</title> <script type="text/javascript" src="../js/vue.js"></script> </head> <!-- 条件渲染 阅读全文
摘要:
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>props的函数组件实现</title> <script src="https://unpkg.com/react@18/umd/react.development.js"></s 阅读全文
摘要:
1.类外写法 <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>props类型限制</title> <script src="https://unpkg.com/react@18/umd/react.development.js" 阅读全文
摘要:
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>props的基本使用</title> <script src="https://unpkg.com/react@18/umd/react.development.js"></scr 阅读全文
摘要:
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>state的简写形式</title> <script src="https://unpkg.com/react@18/umd/react.development.js"></scr 阅读全文
摘要:
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>setState</title> <script src="https://unpkg.com/react@18/umd/react.development.js"></scrip 阅读全文
摘要:
一、state是什么 从字面上来书state就是状态,在React中,state驱动页面的展示,它负责存放数据。 二、state的使用 <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>初始化state</title> <scri 阅读全文
摘要:
1.函数式组件 <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>函数式组件</title> <script src="https://unpkg.com/react@18/umd/react.development.js"></ 阅读全文
摘要:
1.jsx语法 <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>jsx语法</title> <script src="https://unpkg.com/react@18/umd/react.development.js"></ 阅读全文
摘要:
1.使用js创建虚拟DOM(不推荐使用) <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>js创建虚拟DOM</title> <script src="https://unpkg.com/react@18/umd/react.d 阅读全文