- ?? ??? ?? ??? ? HTML? React? ?? ???? ?? ????? ?? ???? ???? ?? ?? ?? UI ??? ??? ? ?????. ?? ??? ??? ????? ?? ??? ???? ???? ????. 2. ????? ? ???? ???? ?? ????? ?? ???? ???? ?? usestate ? useffect? ???? ??? ???? ???? Window ?? LocalStorage? ?? ????? ?? ???? ???? ??? ???? ?????. 3. ??? ?????? ??? ?? ???? ?? ? ? ??? ?? ? ??? ?? ???? ???? ??? ???? ???? ?????. 4. ??? ?? ?? ??? ?? ???? ?? ?? ?? ????? ????? ? ??? ?? ? ?????? ?? ?? ?? ?? ??? ??????. 5. ??? ???? SSR ?? ??? ??? ???? ???? ???? ???? ?? DOM ??? ????? ??? HTML ??? ?????. 6. ???? ???? ????? ?? ?? ???? ?? ??? ??? ???? ??? ?? DOM ????? ?????. 7. ?? ??? ????? : ??? ?? ??, ?? UI ??? ?? ???? ???, ?? ??? ????, ?? ?? ?? JavaScript?? CSS? ????, ?? ??? ???? ?? ?? ???? ??? ??????. ??? ?????? ?? ? ??? ??? ?????? ????? ?? ???? ?? ??? ???? ?? ??? ??? ? ????.
SSR (Server-Side rendered) ?? ???? (Next.js, Nuxt.js? ?? ? ?? ?? SSR) ?? ????? ?? ??? ? ?? SEO? ?????. ??? ??? ???? gotcha : ?? ?? ? ?? ?????. ?? ?? ??? ? HTML? React (?? VUE ?) ?? ???? ?????? ???? ?? ???? ?? ? ?????. ??? DEV? ??, ??? UI ?? ?? ?? ?? ?? ??.

?? ???? ??? ??? ??? ?????.
?? ? ???? ? ??????
??? ????? ? JavaScript ??? ??? ???? ?? ? ?? HTML? "?? ??"? ???? ???????. React? ?? ??? ? DOM ??? ?????? ??? ? ??? ???? ?? ?????. ?????? ??, ??? ??? ?? ??? ????? ?????.

?? : ??? ??? ???? ?????. ?? : "?? ..."????? : "?????, ???"
? ???? SSR? ???? ??? ???? ?? ?? ?? ??? ??? ? ????.

???? ??? ??? ??
1. ????? ?? ???? ???? ??? ???
?? ??? ?? ? ??? ???? ? API ( window
, localStorage
?? navigator
)? ?? ?? ? ?????? ?? ???? ????? ????.
?? myComponent () { const [ismobile, setismobile] = usestate (false); useeffect (() => { setismobile (Window.innerWidth <768); }, []); <div> {ismobile? '?????': '??????'} </div>; }
?? : ????? window
???? ???? isMobile
false
? ?????. ??? ???????? useEffect
?? ? ??? true
? ? ???? → ?? ???.
??? : ??? ??? ???? ?? ???? 2 ?? ???? ??????.
?? myComponent () { const [isclient, setisclient] = usestate (false); useeffect (() => { setisclient (true); }, []); if (! isclient) { <div> ?? ... </div>; // ?? null ?? ?? ?? ?? ? } ?? <div> {window.innerWidth <768? '???': '????'} </div>; }
?? JS ?? ??? ??? ??? ?? useEffect
?? ?? ?? ?? ??? ??? (CSS ??? ??)? ?? ???? ??????.
2. ?? ?? ???? ??? ???
?? ??? ???? ???? ?? (? :?? ??) ?? ???? ?????? ??? ?? ??? ???? ??????? ??? ???? ?????.
?? userProfile ({userId}) { const [user, setUser] = usestate (null); useeffect (() => { FetchUser (userId). }, [userId]); ?? ???? <h1> {user.name} </h1> : <p>?? ... </p>; }
?? : ??? "?? ..."? ??? ? ? ??? ????? ??? null
? ???? React? "?? ..."? ??? ? ???? ?? ? ? ???? . ??? ????? ? ??? ???? ?? ???? ?? → ???? ??? ? ????.
? ?? ?? ?? : ??? ??? ?? ??? ?? ( getServerSideProps
, load
?)? ???? ??? ???? ??? ???? ?????.
// next.js ?? Async ?? ???? GetServersideProps () { const user = wetchuser ()? ?????. return {props : {user}}; } function userProfile ({user}) { ?? <h1> {user.name} </h1>; }
?? ??? ????? ?? ????? ??? ?? ??????.
3. ?? ?? ???? ?? ?? ???
?? ?? () { const time = new date (). tolocaletimestring (); ?? <div> {time} </div>; }
?? : ??? ??? ????? ?????? ?? ?? → ???? ??????.
??? : ???? ?? ???? ????? ??? ??? ??????.
?? ?? () { const [time, settime] = usestate (new date (). tolocaletimestring ()); useeffect (() => { const interval = setInterval (() => { settime (? ?? (). tolocaletimestring ()); }, 1000); return () => clearinterval (??); }, []); ?? <div> {time} </div>; }
??? ?? : ?? ??? ??? ??? ????? ???? ???? new Date()
?????. ???? ?? ??? ?? ?? ? ? ????. ??? ???? ?? ?? ?? ??? ??? ????? Mount??? ????????.
const [time, settime] = usestate ( '...');
4. ??? ? HTML ??
?? ?? ?? ????? ??? ??? ? ????.
{user && <p> ??, {user.name} </p>}
user
????? null
??? ????? (?? ? ??)??? ??? ?? DOM ??? ????.
?? : SSR ?? ??? ???? ???? ???? ??? ? ??? ??????. ??? ?? ??? ???? ???? ??? ??? ??????.
?? ???? ?? ? ??? ?? ?? ?? ??? ????? ????.
5. ?? ???? ?? ??
??? (??, ??, ??)? ???? ?????? ?? ?? ? DOM? ???? ???? ????.
??? : ?????? ?? ?? ? ?? ??????????.
useeffect (() => { const script = document.createElement ( '????'); script.src = 'https://example.com/widget.js'; document.body.appendChild (????); }, []);
SSR ???? ???? ?? useClient
?? isClient
??? ?? ??? ?????.
?? ??? ????? ?? ??
- ? ???? ???? ???? ????? (SSR ??? ? ?????).
- eivise ??? UI? ???? ?? ??? ???
useEffect
????? . - ?
useEffect
???? "?? ?"???? ?? ?? ???? ????? ?? ???? ???????. - Server ?? ? ?????? ?? ??? ????? . ??? ?? ???? API? ???? ????.
- JS ?? ??? ?? CSS? ?? ? ??? ????? .
-
suppressHydrationWarning={true}
??? ?????? (??? ??? ?? ??? ?).
<div suppresshydrationwarning> {math.random ()} </div>
??? ??? ????? ???? ??? ????? ????. ???? ??????.
?? ??? ?? ???? ??-????? ?? ?????. ??? ??? ? ?? ????? ?? ? ???? ???? ?????? ???? ??? ?? ? ? ????.
????? : ???? ?? ? ??? ?? ?? ??? ??? ??? ???? .
? ??? ?? ? ??? ? ?? ?????? ?? ?? ??? ?? ?????. ??? ??? PHP ??? ????? ?? ?? ??? ?????!

? AI ??

Undress AI Tool
??? ???? ??

Undresser.AI Undress
???? ?? ??? ??? ?? AI ?? ?

AI Clothes Remover
???? ?? ???? ??? AI ?????.

Clothoff.io
AI ? ???

Video Face Swap
??? ??? AI ?? ?? ??? ???? ?? ???? ??? ?? ????!

?? ??

??? ??

???++7.3.1
???? ?? ?? ?? ???

SublimeText3 ??? ??
??? ??, ???? ?? ????.

???? 13.0.1 ???
??? PHP ?? ?? ??

???? CS6
??? ? ?? ??

SublimeText3 Mac ??
? ??? ?? ?? ?????(SublimeText3)

ariaattributesenhancewebaccessibilityforuserswithdisabilities withditionalsominticinformationstivetechnologies.theyareneededbecausemodernjavascript-heavycomponentsoftenlackthebuilt-in-inacessibilityfeaturesofnativehtmlelements ? Ariafill

React ??? ???? ???? ?? ????? ??? ??? ??? ????? ?? ? ??? ??? ?????. 1. eseref? ?? ?? ?? ??? ?? ????? ???? ??? ????? ???? ???? ?? ??? ??????. 2. ARIA ??? ???? ? ?? ??? ?? ? ?? ??? ?? ???? ??????. 3. ??? ????????? ??? ?? ??? ?? ?? ??? ?? ??? ???????. 4. ???? HTML ??? ???? ??? ?? ??? ???? ? ?? ??? ????. 5. REACT? DOM? ???? ARIA ??? ???? ???? ????? ??? ??? ??? ?????? ?? ????.

?? ??? ?? ?? ??? ? ???. ??? ??, ??? ?? ? ?? ??? HTTP ??? ??? ?? ?????. 1. CSS ? JavaScript ??? ???? ?? ??? ?? ?? ??? ??? ???? ?? ?? ??? ?????. 2. Picture Sprite ?? Inline Base64 ??? ???? ?? ?? ???? ??? ??? ?? ?? ????. 3. ???? ?? ??? ???? CDN?? ?????? ????? ????? ??? ??? ??? ??? ?? ??? ?? ??? ??????. 4.?? ?????? = "???"?? ????? ???? ??? ?? ??? ??? ????? ?? ??? ??? ??? ??? ??? ??? ?????????. ??? ??? ?? ??? ?? ??? ?????? ? ????? ??? ?? ??? ? ? ????.

Shallowrenderingtestsacomponentinisolation,withoutchildren,whilefullrenderingincludesallchildcomponents.Shallowrenderingisgoodfortestingacomponent’sownlogicandmarkup,offeringfasterexecutionandisolationfromchildbehavior,butlacksfulllifecycleandDOMinte

StrictMode? React?? ??? ???? ?????? ??? ?? ?? ?? ?????. ?? ??? ???? ??? ? ??, ?? ??? ?? ?????? ?? ?? ??? ?? ??? ??? ??? ??? ????? ?? ????. ?????, ???? ?? ???? ??? ????? ??? ???? ???? ???? ??? ??? ??? ??? ?? ?????. ?? ?? ??? ?? ????? ??? ???? ??? ???? ???? ???? ?? ??? ??? ?? ??? ??? ???? ?? ? ? ????. ??? ??? ?? useref ?? ?? ??? ?? ?? REF ??? ????? ?????. stri? ????? ?????

?? ? ?? ???? ???? ?? ???? ??? ? ??? VueCli ?? Vite? ???? TypeScript ?? ????? ????. ?? ??? ??? ???? ?? ???? ?? ??? ???? ?? ? ?? ??? ?? ??? ???? ????? ?? ??? ???? ??? ??? ???? ?? ????. ?? ???? Ref ? Reactive? ??? ? ??? ?? ??? ?????? ?? ?? ?? ? ?? ???? ????? ?? ????.

Server-Siderendering (ssr) innext.jsgenerateshtmlontheserverfireachrequest, ?? ? proformanceandseo.1.ssrisidealfordynamiccontentthatchangangesfrequely, suchasserdashboards.2

VUE ??? ?? ? ? ????? ? ? ?? ?? ??? ????. 1. V- ??? ???? ??? ???? ???? ?? ???? ??????. 2. ?? ??? ???? ?? ?? ??? ?????. 3. ?? ?? ? ???? ?? ? ?? ???? ??????. VUE?? ?? ??, ??? ?? ?? ?? ??? ??? ??? ???? ????? ? V- ??? ?? ??? ??? ??? ? ? ????. ?? ??? ?? ?? ????? ?? ??? ??? ??? ????? ?? ??? ?? ???? ???????. ?? ??? ??? ?? ?? ?? ?? ?????? ?? ??? ? ????. ???? ???? ??? ?? ??? ????, ??? ? ?? ??? ????, ??? ????? ? ??? ??? ???? ?? ?????. ?? ??, ? ??? ?? ??? ??? ???? ?? ValidateForm ???? ?????. ??? ? ???????
