React Hook 的底层实现原理
<h2><span style="font-size: 18px"><strong>原文</strong></span></h2><p><span style="font-size: 14px">https://medium.com/the-guild/under-the-hood-of-reacts-hooks-system-eb59638c9dba</span></p>
<h2><span style="font-size: 18px"><strong>前言</strong></span></h2>
<p><span style="font-size: 15px"> 新的React Hook系统在社区中引起的反响很大。人们纷纷动手尝试,并为之兴奋不已。一想到 hooks 时它们似乎是某种魔法,React 以某种甚至不用暴露其实例(起码没有用到这个关键词)的手段管理了你的组件。那么 React 究竟捣了什么鬼呢?</span></p>
<p><span style="font-size: 15px"> 本文让我们来深入 React 关于 hooks 的实现以更好地理解它。这个魔法特性的问题就在于一旦其发生了问题是难以调试的,因为它隐藏在了一个复杂的堆栈追踪的背后。因此,深入理解 React 的 hooks 系统,我们就能在遭遇它们时相当快地解决问题,或至少能在早期阶段避免它们。</span></p>
<p><span style="font-size: 15px"> </span> 我开始之前,我首先要声明我并不是React的开发者/维护者,因此,大家不要太信任我的观点。我确实非常深入地研究了React hooks的实现,但是无论如何我也不能保证这就是hooks的实际实现原理。话虽如此,我已经用React源码来支持我的观点,并尝试着使我的论点尽可能的真实。</p>
<div> </div>
<p><span style="font-size: 15px"><img src="https://img2020.cnblogs.com/blog/1207967/202008/1207967-20200826143226346-2016386976.png" alt="" loading="lazy"></span></p>
<p> </p>
<p> </p>
<p> </p>
<div>
<p>首先,让我们进入需要确保hooks在React的作用域调用的机制,因为你现在可能知道如果在没有正确的上下文调用钩子是没有意义的:</p>
<h1>The dispatcher</h1>
<p>dispatcher 是包含了hooks函数的共享对象。它将根据ReactDom的渲染阶段来动态分配或者清除,并且确保用户无法在 React 组件外访问hooks。请参阅实现</p>
<p>我们可以在渲染根组件前通过简单的切换来使用正确的dispatcher,用一个叫做enableHooks的标志来开启/禁用;这意味这从技术上来说,我们可以在运行时开启/禁用挂钩。React 16.6.x就已经有了试验性的实现,只不过它是被禁用的。请参阅实现</p>
<p>当我们执行完渲染工作时,我们将dispatcher 置空从而防止它在ReactDOM的渲染周期之外被意外调用。这是一种可以确保用户不做傻事的机制。请参阅实现</p>
<p>dispatcher 在每一个 hook 调用中 使用resolveDispatcher()这个函数来调用。就像我之前说的,在React的渲染周期之外调用是毫无意义的,并且React会打印出警告信息“Hooks只能在函数组件的主体内部调用”请参照实现</p>
</div>
<div class="cnblogs_code">
<pre><span style="color: rgba(0, 0, 0, 1)">let currentDispatcher
const dispatcherWithoutHooks </span>= { <span style="color: rgba(0, 128, 0, 1)">/*</span><span style="color: rgba(0, 128, 0, 1)"> ... </span><span style="color: rgba(0, 128, 0, 1)">*/</span><span style="color: rgba(0, 0, 0, 1)"> }
const dispatcherWithHooks </span>= { <span style="color: rgba(0, 128, 0, 1)">/*</span><span style="color: rgba(0, 128, 0, 1)"> ... </span><span style="color: rgba(0, 128, 0, 1)">*/</span><span style="color: rgba(0, 0, 0, 1)"> }
</span><span style="color: rgba(0, 0, 255, 1)">function</span><span style="color: rgba(0, 0, 0, 1)"> resolveDispatcher() {
</span><span style="color: rgba(0, 0, 255, 1)">if</span> (currentDispatcher) <span style="color: rgba(0, 0, 255, 1)">return</span><span style="color: rgba(0, 0, 0, 1)"> currentDispatcher
</span><span style="color: rgba(0, 0, 255, 1)">throw</span> Error("Hooks can't be called"<span style="color: rgba(0, 0, 0, 1)">)
}
</span><span style="color: rgba(0, 0, 255, 1)">function</span><span style="color: rgba(0, 0, 0, 1)"> useXXX(...args) {
const dispatcher </span>=<span style="color: rgba(0, 0, 0, 1)"> resolveDispatcher()
</span><span style="color: rgba(0, 0, 255, 1)">return</span><span style="color: rgba(0, 0, 0, 1)"> dispatcher.useXXX(...args)
}
</span><span style="color: rgba(0, 0, 255, 1)">function</span><span style="color: rgba(0, 0, 0, 1)"> renderRoot() {
currentDispatcher </span>= enableHooks ?<span style="color: rgba(0, 0, 0, 1)"> dispatcherWithHooks : dispatcherWithoutHooks
performWork()
currentDispatcher </span>= <span style="color: rgba(0, 0, 255, 1)">null</span><span style="color: rgba(0, 0, 0, 1)">
}</span></pre>
</div>
<div>
<div>
<p> </p>
<p>到此为止既然我们已经看过了这种简单的封装机制,我希望我们转到本文的核心 - Hooks。我想向您介绍一个新概念:</p>
<h2>The hooks queue</h2>
<p>在使用场景之后,hooks表示为在调用顺序下链接在一起的节点。它们被表示成这样是因为hooks并不是简单的创建然后又把它遗留下来。它们有一种可以让他们变成它们自己的机制。一个Hook有几个我希望你可以在深入研究实现之前记住的属性:</p>
<ol>
<li>它的初始状态在首次渲染时被创建。</li>
<li>她的状态可以即时更新。</li>
<li>React会在之后的渲染中记住hook的状态</li>
<li>React会根据调用顺序为您提供正确的状态</li>
<li>React会知道这个hook属于哪个Fiber。</li>
</ol>
<p>因此,我们需要重新思考我们查看组件状态的方式。到目前为止,我们认为它就像是一个普通的对象:</p>
</div>
<div class="cnblogs_code">
<pre><span style="color: rgba(0, 0, 0, 1)">{
foo: </span>'foo'<span style="color: rgba(0, 0, 0, 1)">,
bar: </span>'bar'<span style="color: rgba(0, 0, 0, 1)">,
baz: </span>'baz'<span style="color: rgba(0, 0, 0, 1)">,
}</span></pre>
</div>
<p>但是在处理hook时,它应该被视为一个队列,其中每个节点代表一个状态的单个模型:</p>
<p> </p>
<div class="cnblogs_code">
<pre><span style="color: rgba(0, 0, 0, 1)">{
memoizedState: </span>'foo'<span style="color: rgba(0, 0, 0, 1)">,
next: {
memoizedState: </span>'bar'<span style="color: rgba(0, 0, 0, 1)">,
next: {
memoizedState: </span>'bar'<span style="color: rgba(0, 0, 0, 1)">,
next: </span><span style="color: rgba(0, 0, 255, 1)">null</span><span style="color: rgba(0, 0, 0, 1)">
}
}
}</span></pre>
</div>
<div>
<div>
<p> </p>
<p>可以在实现中查看单个hook节点的模式。你会看到hook有一些额外的属性,但是理解钩子如何工作的关键在于memoizedState和next。其余属性由useReducer()hook专门用于缓存已经调度的操作和基本状态,因此在各种情况下,还原过程可以作为后备重复:<br>
· baseState - 将给予reducer的状态对象。<br>
· baseUpdate- 最近的创建了最新baseState的调度操作。<br>
· queue - 调度操作的队列,等待进入reducer。</p>
<p>不幸的是,我没有设法很好地掌握reducer hook,因为我没有设法重现任何边缘情况,所以我不觉得舒服去精心设计。我只能说,reducer 的实现是如此不一致,在代码注释中甚至指出,“不知道这些是否都是所需的语义”; 所以我该如何确定?!</p>
<p>所以回到hooks,在每个函数组件调用之前,将调用一个名为prepareHooks()的函数,其中当前fiber及其hooks队列中的第一个hook节点将被存储在全局变量中。这样,只要我们调用一个hook函数(useXXX()),就会知道要在哪个上下文中运行。</p>
</div>
<div class="cnblogs_code">
<pre><span style="color: rgba(0, 0, 0, 1)">let currentlyRenderingFiber
let workInProgressQueue
let currentHook
</span><span style="color: rgba(0, 128, 0, 1)">//</span><span style="color: rgba(0, 128, 0, 1)"> Source: https://github.com/facebook/react/tree/5f06576f51ece88d846d01abd2ddd575827c6127/react-reconciler/src/ReactFiberHooks.js:123</span>
<span style="color: rgba(0, 0, 255, 1)">function</span><span style="color: rgba(0, 0, 0, 1)"> prepareHooks(recentFiber) {
currentlyRenderingFiber </span>=<span style="color: rgba(0, 0, 0, 1)"> workInProgressFiber
currentHook </span>=<span style="color: rgba(0, 0, 0, 1)"> recentFiber.memoizedState
}
</span><span style="color: rgba(0, 128, 0, 1)">//</span><span style="color: rgba(0, 128, 0, 1)"> Source: https://github.com/facebook/react/tree/5f06576f51ece88d846d01abd2ddd575827c6127/react-reconciler/src/ReactFiberHooks.js:148</span>
<span style="color: rgba(0, 0, 255, 1)">function</span><span style="color: rgba(0, 0, 0, 1)"> finishHooks() {
currentlyRenderingFiber.memoizedState </span>=<span style="color: rgba(0, 0, 0, 1)"> workInProgressHook
currentlyRenderingFiber </span>= <span style="color: rgba(0, 0, 255, 1)">null</span><span style="color: rgba(0, 0, 0, 1)">
workInProgressHook </span>= <span style="color: rgba(0, 0, 255, 1)">null</span><span style="color: rgba(0, 0, 0, 1)">
currentHook </span>= <span style="color: rgba(0, 0, 255, 1)">null</span><span style="color: rgba(0, 0, 0, 1)">
}
</span><span style="color: rgba(0, 128, 0, 1)">//</span><span style="color: rgba(0, 128, 0, 1)"> Source: https://github.com/facebook/react/tree/5f06576f51ece88d846d01abd2ddd575827c6127/react-reconciler/src/ReactFiberHooks.js:115</span>
<span style="color: rgba(0, 0, 255, 1)">function</span><span style="color: rgba(0, 0, 0, 1)"> resolveCurrentlyRenderingFiber() {
</span><span style="color: rgba(0, 0, 255, 1)">if</span> (currentlyRenderingFiber) <span style="color: rgba(0, 0, 255, 1)">return</span><span style="color: rgba(0, 0, 0, 1)"> currentlyRenderingFiber
</span><span style="color: rgba(0, 0, 255, 1)">throw</span> Error("Hooks can't be called"<span style="color: rgba(0, 0, 0, 1)">)
}
</span><span style="color: rgba(0, 128, 0, 1)">//</span><span style="color: rgba(0, 128, 0, 1)"> Source: https://github.com/facebook/react/tree/5f06576f51ece88d846d01abd2ddd575827c6127/react-reconciler/src/ReactFiberHooks.js:267</span>
<span style="color: rgba(0, 0, 255, 1)">function</span><span style="color: rgba(0, 0, 0, 1)"> createWorkInProgressHook() {
workInProgressHook </span>= currentHook ?<span style="color: rgba(0, 0, 0, 1)"> cloneHook(currentHook) : createNewHook()
currentHook </span>=<span style="color: rgba(0, 0, 0, 1)"> currentHook.next
workInProgressHook
}
</span><span style="color: rgba(0, 0, 255, 1)">function</span><span style="color: rgba(0, 0, 0, 1)"> useXXX() {
const fiber </span>=<span style="color: rgba(0, 0, 0, 1)"> resolveCurrentlyRenderingFiber()
const hook </span>=<span style="color: rgba(0, 0, 0, 1)"> createWorkInProgressHook()
</span><span style="color: rgba(0, 128, 0, 1)">//</span><span style="color: rgba(0, 128, 0, 1)"> ...</span>
<span style="color: rgba(0, 0, 0, 1)">}
</span><span style="color: rgba(0, 0, 255, 1)">function</span><span style="color: rgba(0, 0, 0, 1)"> updateFunctionComponent(recentFiber, workInProgressFiber, Component, props) {
prepareHooks(recentFiber, workInProgressFiber)
Component(props)
finishHooks()
}</span></pre>
</div>
<div>
<div> </div>
<div>一旦更新完成,一个叫做finishHooks()的函数将被调用,其中hooks队列中第一个节点的引用将存储在渲染完成的fiber对象的memoizedState属性中。这意味着hooks队列及其状态可以在外部被定位</div>
<div>到:</div>
<div> </div>
<div class="cnblogs_code">
<pre>const ChildComponent = () =><span style="color: rgba(0, 0, 0, 1)"> {
useState(</span>'foo'<span style="color: rgba(0, 0, 0, 1)">)
useState(</span>'bar'<span style="color: rgba(0, 0, 0, 1)">)
useState(</span>'baz'<span style="color: rgba(0, 0, 0, 1)">)
</span><span style="color: rgba(0, 0, 255, 1)">return</span> <span style="color: rgba(0, 0, 255, 1)">null</span><span style="color: rgba(0, 0, 0, 1)">
}
const ParentComponent </span>= () =><span style="color: rgba(0, 0, 0, 1)"> {
const childFiberRef </span>=<span style="color: rgba(0, 0, 0, 1)"> useRef()
useEffect(() </span>=><span style="color: rgba(0, 0, 0, 1)"> {
let hookNode </span>=<span style="color: rgba(0, 0, 0, 1)"> childFiberRef.current.memoizedState
assert(hookNode.memoizedState, </span>'foo'<span style="color: rgba(0, 0, 0, 1)">)
hookNode </span>=<span style="color: rgba(0, 0, 0, 1)"> hooksNode.next
assert(hookNode.memoizedState, </span>'bar'<span style="color: rgba(0, 0, 0, 1)">)
hookNode </span>=<span style="color: rgba(0, 0, 0, 1)"> hooksNode.next
assert(hookNode.memoizedState, </span>'baz'<span style="color: rgba(0, 0, 0, 1)">)
})
</span><span style="color: rgba(0, 0, 255, 1)">return</span><span style="color: rgba(0, 0, 0, 1)"> (
</span><ChildComponent ref={childFiberRef} />
<span style="color: rgba(0, 0, 0, 1)">)
}</span></pre>
</div>
<div>
<div>
<p>让我们更具体一点,谈谈各个hooks,从最常见的state hook开始:</p>
<h2>State hooks</h2>
<p>你将惊讶的了解到useState hook使用的useReducer只是为它提供了一个预定义的reducer处理程序请参阅实现。这意味着实际上useState返回的结果是一个reducer状态和一个action dispatcher。我希望你看一下state hook使用的reducer处理程序:</p>
</div>
<div class="cnblogs_code">
<pre><span style="color: rgba(0, 0, 255, 1)">function</span><span style="color: rgba(0, 0, 0, 1)"> basicStateReducer(state, action) {
</span><span style="color: rgba(0, 0, 255, 1)">return</span> <span style="color: rgba(0, 0, 255, 1)">typeof</span> action === 'function' ?<span style="color: rgba(0, 0, 0, 1)"> action(state) : action;
}</span></pre>
</div>
<div>
<div> </div>
<div>正如预期的那样,我们可以直接为action dispatcher提供新的状态; 但你会看那个吗?!我们还可以为dispatcher提供一个动作函数,该函数将接收旧状态并返回新状态。这意味着,当你将状态设置器传递到子组件时,你可以改变当前父组件的状态,不需要作为一个不同的prop传递下去。</div>
<div> </div>
<div>举个例子:</div>
<div class="cnblogs_code">
<pre>const ParentComponent = () =><span style="color: rgba(0, 0, 0, 1)"> {
const </span>=<span style="color: rgba(0, 0, 0, 1)"> useState()
</span><span style="color: rgba(0, 0, 255, 1)">return</span><span style="color: rgba(0, 0, 0, 1)"> (
</span><ChildComponent toUpperCase={setName} />
<span style="color: rgba(0, 0, 0, 1)">)
}
const ChildComponent </span>= (props) =><span style="color: rgba(0, 0, 0, 1)"> {
useEffect(() </span>=><span style="color: rgba(0, 0, 0, 1)"> {
props.toUpperCase((state) </span>=><span style="color: rgba(0, 0, 0, 1)"> state.toUpperCase())
}, [</span><span style="color: rgba(0, 0, 255, 1)">true</span><span style="color: rgba(0, 0, 0, 1)">])
</span><span style="color: rgba(0, 0, 255, 1)">return</span> <span style="color: rgba(0, 0, 255, 1)">null</span></pre>
</div>
<div>
<div>
<p>最后,effect hooks - 它对组件的生命周期及其工作方式产生了重大影响:</p>
<h2>Effect hooks</h2>
<p>Effect hooks 的行为略有不同,并且有一个额外的逻辑层,我接下来会解释。同样,在我深入了解实现之前,我希望你能记住effect hooks的属性:</p>
<ol>
<li>它们是在渲染时创建的,但它们在绘制后运行。</li>
<li>它们将在下一次绘制之前被销毁。</li>
<li>它们按照已经被定义的顺序执行。</li>
</ol>
<blockquote>
<p>请注意,我使用的是“绘制”术语,而不是“渲染”。这两个是不同的东西,我看到最近React Conf中的许多发言者使用了错误的术语!即使在官方的React文档中,他们也会说“在渲染屏幕之后”,在某种意义上应该更像“绘制”。render方法只创建fiber节点,但没有绘制任何东西。</p>
</blockquote>
<p>因此,应该有另一个额外的队列保持这些effect,并应在绘制后处理。一般而言,fiber保持包含effect节点的队列。每种effect都是不同的类型,应在适当的阶段处理:</p>
<p> </p>
<p>· 在变化之前调用实例的getSnapshotBeforeUpdate()方法请参阅实现。<br>
·执行所有节点的插入,更新,删除和ref卸载操作请参阅实现。<br>
·执行所有生命周期和ref回调。生命周期作为单独的过程发生,因此整个树中的所有放置,更新和删除都已经被调用。此过程还会触发任何特定渲染的初始effects请参阅实现。<br>
·由useEffect() hook 安排的effects - 基于实现也被称为“passive effects” (也许我们应该在React社区中开始使用这个术语?!)。</p>
<p>当涉及到hook effects时,它们应该存储在fiber的一个名为 updateQueue的属性中,并且每个effect node应该具有以下模式请参阅实现:</p>
<p> </p>
<p>· tag - 一个二进制数,它将决定effect的行为(我将尽快阐述)。<br>
· create- 绘制后应该运行的回调。<br>
· destroy- 从create()返回的回调应该在初始渲染之前运行。<br>
· inputs - 一组值,用于确定是否应销毁和重新创建effect。<br>
· next - 函数组件中定义的下一个effect的引用。</p>
<p> </p>
<p>除了tag属性外,其他属性都非常简单易懂。如果你已经很好地研究了hooks,你就会知道React为你提供了几个特殊的hooks:useMutationEffect()和useLayoutEffect()。这两种效果在内部使用useEffect(),这实际上意味着它们创建了一个effect节点,但它们使用不同的tag值。</p>
<p>标签由二进制值组合而成请参阅实现:</p>
</div>
</div>
<div class="cnblogs_code">
<pre>const NoEffect = <span style="color: rgba(0, 128, 0, 1)">/*</span> <span style="color: rgba(0, 128, 0, 1)">*/</span><span style="color: rgba(0, 0, 0, 1)"> 0b00000000;
const UnmountSnapshot </span>= <span style="color: rgba(0, 128, 0, 1)">/*</span> <span style="color: rgba(0, 128, 0, 1)">*/</span><span style="color: rgba(0, 0, 0, 1)"> 0b00000010;
const UnmountMutation </span>= <span style="color: rgba(0, 128, 0, 1)">/*</span> <span style="color: rgba(0, 128, 0, 1)">*/</span><span style="color: rgba(0, 0, 0, 1)"> 0b00000100;
const MountMutation </span>= <span style="color: rgba(0, 128, 0, 1)">/*</span> <span style="color: rgba(0, 128, 0, 1)">*/</span><span style="color: rgba(0, 0, 0, 1)"> 0b00001000;
const UnmountLayout </span>= <span style="color: rgba(0, 128, 0, 1)">/*</span> <span style="color: rgba(0, 128, 0, 1)">*/</span><span style="color: rgba(0, 0, 0, 1)"> 0b00010000;
const MountLayout </span>= <span style="color: rgba(0, 128, 0, 1)">/*</span> <span style="color: rgba(0, 128, 0, 1)">*/</span><span style="color: rgba(0, 0, 0, 1)"> 0b00100000;
const MountPassive </span>= <span style="color: rgba(0, 128, 0, 1)">/*</span> <span style="color: rgba(0, 128, 0, 1)">*/</span><span style="color: rgba(0, 0, 0, 1)"> 0b01000000;
const UnmountPassive </span>= <span style="color: rgba(0, 128, 0, 1)">/*</span> <span style="color: rgba(0, 128, 0, 1)">*/</span> 0b10000000;</pre>
</div>
<p> </p>
<div>
<div>
<p>这些二进制值的最常见用例是使用管道(|)将这些位按原样添加到单个值。然后我们可以使用&符号(&)检查标签是否实现某种行为。如果结果为非零,则表示tag实现了指定的行为。</p>
<p>以下是React支持的hook effect类型及其标签请参阅实现:</p>
<p>Default effect — UnmountPassive | MountPassive.<br>
Mutation effect — UnmountSnapshot | MountMutation.<br>
Layout effect — UnmountMutation | MountLayout.<br>
以下是React如何检查行为实现请参阅实现:</p>
</div>
<div class="cnblogs_code">
<pre><span style="color: rgba(0, 0, 255, 1)">if</span> ((effect.tag & unmountTag) !==<span style="color: rgba(0, 0, 0, 1)"> NoHookEffect) {
</span><span style="color: rgba(0, 128, 0, 1)">//</span><span style="color: rgba(0, 128, 0, 1)"> Unmount</span>
<span style="color: rgba(0, 0, 0, 1)">}
</span><span style="color: rgba(0, 0, 255, 1)">if</span> ((effect.tag & mountTag) !==<span style="color: rgba(0, 0, 0, 1)"> NoHookEffect) {
</span><span style="color: rgba(0, 128, 0, 1)">//</span><span style="color: rgba(0, 128, 0, 1)"> Mount</span>
}</pre>
</div>
<p> </p>
<p>因此,基于我们刚刚学到的关于effect hooks的内容,我们实际上可以在外部向某个fiber注入effect:</p>
<div class="cnblogs_code">
<pre><span style="color: rgba(0, 0, 255, 1)">function</span><span style="color: rgba(0, 0, 0, 1)"> injectEffect(fiber) {
const lastEffect </span>=<span style="color: rgba(0, 0, 0, 1)"> fiber.updateQueue.lastEffect
const destroyEffect </span>= () =><span style="color: rgba(0, 0, 0, 1)"> {
console.log(</span>'on destroy'<span style="color: rgba(0, 0, 0, 1)">)
}
const createEffect </span>= () =><span style="color: rgba(0, 0, 0, 1)"> {
console.log(</span>'on create'<span style="color: rgba(0, 0, 0, 1)">)
</span><span style="color: rgba(0, 0, 255, 1)">return</span><span style="color: rgba(0, 0, 0, 1)"> destroy
}
const injectedEffect </span>=<span style="color: rgba(0, 0, 0, 1)"> {
tag: 0b11000000,
next: lastEffect.next,
create: createEffect,
destroy: destroyEffect,
inputs: ,
}
lastEffect.next </span>=<span style="color: rgba(0, 0, 0, 1)"> injectedEffect
}
const ParentComponent </span>=<span style="color: rgba(0, 0, 0, 1)"> (
</span><ChildComponent ref={injectEffect} />
)</pre>
</div>
<p style="text-align: center"> </p>
<p style="text-align: center"> </p>
<p style="text-align: center"><img src="https://mmbiz.qpic.cn/mmbiz_png/ic5A4V8PX4PmYRMdf2zNTI5ibzzjibIRoBHXEFlX0W4k2AJCl5brCt69CEtoPJSErVxpKvNictXlq5ZOfiafEgCmScQ/640?wx_fmt=png" data-ratio="0.057692307692307696" data-type="png" data-w="208" data-width="100%">文章就分享到这,欢迎关注“前端大神之路”<img src="https://mmbiz.qpic.cn/mmbiz_png/ic5A4V8PX4PmYRMdf2zNTI5ibzzjibIRoBHXEFlX0W4k2AJCl5brCt69CEtoPJSErVxpKvNictXlq5ZOfiafEgCmScQ/640?wx_fmt=png" data-ratio="0.057692307692307696" data-type="png" data-w="208" data-width="100%"><em id="__mceDel"> </em></p>
<p style="text-align: center"><img src="https://mmbiz.qpic.cn/mmbiz_jpg/ic5A4V8PX4PlFsF8IR1HCWm1d4NkicdsocH4vNZlgibKwBuf0HbtdpsC3a7YGvDIYGrgIM88ADywXHc7rPOGqibeqg/640?wx_fmt=jpeg" width="454" height="189" class="rich_pages" data-ratio="0.4166666666666667" data-s="300,640" data-type="jpeg" data-w="720"></p>
<p style="text-align: center"> </p>
</div>
</div>
</div>
</div>
</div>
</div><br><br>
来源:https://www.cnblogs.com/cczlovexw/p/13565085.html
頁:
[1]