覆盖 200 条帖子 · 2023年1月2日 至 2026年11月26日(UTC)
- 粉丝数
- —
- 互动率 —
- 每帖平均浏览量
- 80.1K
- 浏览量中位数 38.1K
- 每帖平均点赞数
- 525
- 点赞率 0.656%
- 每帖平均回复数
- 13.6
- 回复率 0.017%
- 每帖平均转发数
- 32.5
- 转发率 0.0406%
- 每帖平均收藏数
- 258
- 收藏率 0.322%
Shu的内容涵盖前端开源库与工具发布、AI 辅助开发与产品动态和React 与 Next.js 框架实践等主题。结合帖子表现、内容形式和发布时段,查看对应原帖。
React 与 Next.js 框架实践
I wrote a blog post: Building Bulletproof React Components:
https://t.co/xWD215YaFi
图片加载中…Statically typed links are coming to @nextjs:
◆ Autocompletion ◆ Error on invalid routes ◆ Prevents 404 links during build ◆ Dynamic, catch-all, and optional catch-all routes ◆ Works with both `pages` and `app` ◆ No extra configuration needed! https://t.co/E04vzfTxA1
SPEC-01/HARDWARE
Themed components built with @Vercel UI SDK https://t.co/AUgwyAp1E0 Sound on https://t.co/p1sOIbZbYW
If you’re wondering what UI SDK behaviors look like in real components, we’ve put together some examples you can try:
https://t.co/eenRpMex56 https://t.co/EsZxu1fNi4
Easy-to-use CSS View Transitions API helpers for Next.js App Router:
https://t.co/wF4SMHAHh7
We migrated @v0’s codebase from ESLint + Prettier to Oxlint + Oxfmt by @oxcproject, CI is now 3x faster. Love the OSS ecosystem.
New site design: https://t.co/QbhBJs86x6
• Next.js 15 • Tailwind CSS v4 • MDX Rust + Shiki inside React Server Components • <ViewTransition/> from React Experimental https://t.co/3QNZBz87wT https://t.co/l0eujzew4J
图片加载中…In case you didn’t know, React didn’t invent RSC, SSR, or Hydration, conceptually:
SSR is Express: app.get('/', (req, res) => { res.render('index', { name: 'John' }) }) RSC is Pug: if name == "Bob" button(class="btn") Hello Bob else button(class="btn") My name is #{name} Hydration is jQuery: $('.btn').click(...) That’s why there’s no window in SSR, and you can’t set onClick in RSC, and you have hydration errors in jQuery too (such as a typo of .btn) but with a less fancy name.
I’m redesigning my website on top of some exciting new things: Next.js App Router, Turbopack, CSS View Transitions, Tailwind CSS 4.0, MDX in RSC.
Will have it open sourced when it’s ready :) Interestingly Turbopack, Tailwind and MDX compilers are all backed by Rust now. https://t.co/5u9OhoeAYG
My React Server Components (RSC) mental model is basically:
They’re getServerSideProps / getStaticProps but more powerful. Things RSC / gSSP / gSP share in common: 🔸 You can’t pass things like normal functions from RSC / gSSP / gSP to the client, because they just can’t be serialized; 🔸 They must be executed before Client Components; 🔸 They don’t run in the browser; 🔸 They don’t have states, so no hooks; 🔸 They can both be executed and stored as static at build time (RSC / gSP), so they don’t require a server. Things that are more advanced in RSC compared to gSSP / gSP: 🔹 Server Components can pass elements and more to the client, instead of being limited to JSON values; 🔹 Server Components are able to define extra wrappers around Client Components, whereas gSSP / gSP can only affect components’ inner content; 🔹 You can have many Server Components and they will be more parallelized when executing, instead of only one giant gSSP / gSP blocking on the top; 🔹 Individual Server Component boundaries can be optimized as static if possible, instead of picking between fully dynamic (gSSP) and fully static (gSP) for all data; 🔹 Individual Server Component boundaries can be streamed to the browser and rendered earlier, unlike gSSP that must block the initial client rendering.
图片加载中…Next.js 16.3 is really good.
A trick I use a lot: when inlining scoped* JS code as source string, do `(${() => { … }})()`.
- Compiled and minified on prod - TS allowed - Syntax highlight, auto format, type check, lint all work https://t.co/GP67FLp4Cz
图片加载中…One small detail of UI SDK that we’ve put a lot of effort into, to make it more accessible:
A `findable` option to make native search (Ctrl/Cmd+F) work with virtualized lists. Works in both Safari and Chrome. https://t.co/X8QqHotlce https://t.co/FvtY03cAeq
𝑎𝑠𝑦𝑛𝑐 𝑓𝑢𝑛𝑐𝑡𝑖𝑜𝑛 𝐶𝑜𝑚𝑝({ 𝑖𝑑, 𝑐ℎ𝑖𝑙𝑑𝑟𝑒𝑛 }) { "𝑢𝑠𝑒 𝑐𝑎𝑐ℎ𝑒"
𝑐𝑜𝑛𝑠𝑡 𝑑𝑎𝑡𝑎 = 𝑎𝑤𝑎𝑖𝑡 𝑔𝑒𝑡𝑆𝑜𝑚𝑒𝐷𝑎𝑡𝑎(𝑖𝑑) 𝑟𝑒𝑡𝑢𝑟𝑛 <> <𝑑𝑖𝑣>{𝑑𝑎𝑡𝑎}</𝑑𝑖𝑣> {𝑐ℎ𝑖𝑙𝑑𝑟𝑒𝑛} </> } Changing children won’t break the cache.
Trying to visualize that Server-Side Rendering (SSR) isn't just about SEO, it actually makes the site faster. And why PPR is the goat.
Main cost = 🟥 JS load & Hydration 🟡⇆🔵 Region Latency https://t.co/XHctfcEIyc
图片加载中…There are many mind-blowing ideas in RSC’s design, but one that still sticks with me is this:
Dynamism starts at reading the data, not getting the data. Does it sound obvious? What does this exactly mean in RSC’s design? First of all, it’s natural to think that all dynamism is introduced by IO operations, and almost all IO is asynchronous. Let’s exclude things like Date and Math.random from this discussion. 1. If a page component is sync, we can safely say that it is static and the result can be cached, because there’s no way to read the data (no `await`). This is the reason that Next.js has `params`, `searchParams`, `headers()`, `cookies()`, etc. as async APIs. 2. Sync doesn’t mean one can’t load the data. If we start loading something as a Promise, the result can still be cached until the moment it’s read (`await`ed). This is why it’s recommended to preload data in RSC and pass it down as a Promise (then `use()` inside). It allows the framework to pre-build and stream a static shell:
图片加载中…Sometimes optimizations are chained and can be destroyed by single point of deopts, which is worse than no optimization at all. That’s also why they should be made by compilers. https://t.co/ziFENK3Jxm
图片加载中…One of those invisible details: accessibility isn’t only screen readers. it’s also “can someone in Tokyo type into your search box without it picking the wrong thing.”
@uisdk handles Input Method Editor (IME) input so keystroke/Enter/Escape/arrows don’t fire mid-word. https://t.co/gQdyiuNgeQ
And I’ll try to draw some diagrams to show how I visualize Server Actions in my head and how they work, as I saw some confusion around. There’re two ways of using Server Actions:
1. Define Server Actions in Server Components and pass them to Client Components via props... https://t.co/Y0szUzMe0K
True but worth noting that the only thing I dislike about this pattern is that it takes 2 render passes to SSR, which breaks the assumption of “hooks are stateless/no-ops on the server”.
That assumption can be very useful. On a server bundle build, the compiler can optimize useState/useMemo/useCallback/useRef calls to just inline values, remove useEffect, etc. for almost all hooks. That essentially eliminates the “ordered internal states” of hooks. And that “server” definition can be broader, anything without actually hydrating the app interactivity can be that “server”. For example a Playwright runtime used to only screenshot the initial render, or tools like Satori to statically render React components into image, etc.
打开引用帖Big productivity boost with GitHub’s stacked PRs, thanks @jaredpalmer https://t.co/pvhU3kVemU
图片加载中…Just in case you weren’t aware, enabling the `experimental.typedRoutes` feature in @nextjs automatically checks for invalid links, along with support for rewrites and redirects! https://t.co/ABD6pj15QG
图片加载中…Why does it have to be compiler magic? Think about this React component (pseudo):
function UserSignup(email) { const step1 = useMemo(() => queueStep('createUser', email)) const user = use(resolveIfStepDone(step1)) const step2 = useMemo(() => queueStep('sendWelcomeEmail', email)) use(resolveIfStepDone(step2)) const step3 = useMemo(() => queueStep('sleep', '7 days')) use(resolvedIfStepDone(step3)) const step4 = useMemo(() => queueStep('sendCheckInEmail', email)) use(resolvedIfStepDone(step4)) return { userId: https://t.co/maDf9NO77K, status: 'done' } } queueStep → tells an external executor to schedule, run, retry, monitor the task and return an ID; resolvedIfStepDone → abort and schedule a “re-render” of workflow, or resolve to the result if that step ID is finished. Unlike regular React, all memorized values and scheduler states are managed and persisted externally. So `await sleep('7 days')` doesn’t actually keep the server waiting, but stops it and restarts it in 7 days. In general, directives (use server/client/cache/workflow/step/dom/…) are ways to declare/hoist compute boundaries that are scoped to re-runnable units with serializable inputs/outputs.
打开引用帖Delivered some value last week! Next.js canary now automatically optimizes barrel file imports of popular libs (lucide-react, react-bootstrap, ant-design/icons, etc.).
A more advanced config is also available for your internal component system to use: https://t.co/1ytxyA5icz https://t.co/Bqj1VI6fXf
图片加载中…The Next.js TypeScript plugin is quite helpful. However, there is no way to enable a TS Language Server plugin by default in VS Code.
To avoid picking Workspace TS Version every time when opening a project, I made this extension to do it automatically: https://t.co/e1jKNcunlh
𝑓𝑢𝑛𝑐𝑡𝑖𝑜𝑛 𝐶𝑜𝑚𝑝({ 𝑖𝑑 }) { 𝑎𝑠𝑦𝑛𝑐 𝑓𝑢𝑛𝑐𝑡𝑖𝑜𝑛 𝑔𝑒𝑡𝑈𝑠𝑒𝑟𝐼𝑡𝑒𝑚𝑠(𝑖𝑛𝑑𝑒𝑥, 𝑙𝑖𝑚𝑖𝑡) { "𝑢𝑠𝑒 𝑐𝑎𝑐ℎ𝑒" 𝑟𝑒𝑡𝑢𝑟𝑛 𝑎𝑤𝑎𝑖𝑡 𝑑𝑏𝐺𝑒𝑡𝑈𝑠𝑒𝑟𝐼𝑡𝑒𝑚𝑠(𝑖𝑑, 𝑖𝑛𝑑𝑒𝑥, 𝑙𝑖𝑚𝑖𝑡) }
𝑟𝑒𝑡𝑢𝑟𝑛 <𝑈𝑠𝑒𝑟 𝑔𝑒𝑡𝐼𝑡𝑒𝑚𝑠={𝑔𝑒𝑡𝑈𝑠𝑒𝑟𝐼𝑡𝑒𝑚𝑠}/> } Here `id` will automatically become part of the cache key, and changing `id` will invalidate the cache even with same parameters. This is also why it can not be cache(fn) and has to be a compiler feature and be statically analyzable.
打开引用帖Upgraded https://t.co/QbhBJs8EmE to Next.js 16 and the deployment time reduced 35% (52s → 34s): https://t.co/UxylRnBfRF
图片加载中…`require('./typescript.js')` takes 0.255s `require('./typescript.min.js')` takes 0.191s
That’s ~25% faster. Publish minified packages if you can. https://t.co/Etip5MISqW
图片加载中…RSC’s serialization protocol is what really shines, and it’s way beyond “component level data fetching”.
Working on the next big release for https://t.co/xQt8aPeeNJ with @B2o5T:
1. Remote MDX 2. Dynamic routes 3. ISR & on-demand ISR Imagine /v2/[…slug].mdx + fallback=blocking + CMS-backed content. Fast, dynamic, scalable. Pick 3.
Some folks have been curious about the additional inlined data in the rendered HTML when using Server Components (and getServerSideProps, too!).
Here's a simplified explanation I shared with a friend: https://t.co/chrn8CrpHL
图片加载中…I need an ESLint rule to sort my code alphabetically so I don’t ship bugs.
Looks so well-organized: https://t.co/WeVibHYxC5
图片加载中…The fake SSR vs the real SSR (this is a joke) https://t.co/GMUKTV4eai
图片加载中…Every time I’m on a flight, I’m grateful for GitHub streaming SSR their pages.
Vercel Skew Protection, React Concurrent Rendering, CSS View Transitions,
Are same things: running multiple versions of your app at the same time. They’re on different levels, they’re all super useful, and they’re not that easy to build.
If you are interested in some of the most impactful improvements @timneutkens and I shipped last week: https://t.co/E44Ttdh0Ds
It’s not finished work and there’re more to come! Please do not hesitate to do a profiling (check the link) and ping us if you saw slowness.
The reason was, I saw this pattern of preloading resources:
let userPromise = loadUser() // other tasks.. try { let user = await userPromise // .. } catch { // handle user load failure } And this might be a footgun if the sync function throws before returning a promise: https://t.co/ZyK4SQFCKX
图片加载中…Is there any reliable way to tell if a `fetch` was aborted because of the device being turned into sleep mode?
All the hacks I know use setInterval which delay the detection a bit and are not elegant…
RSC payloads are flowing out like endless rain into a paper cup They slither wildly as they slip away across the universe
Let’s say `f()` returns a promise:
async function a() { return f() } async function b() { return await f() } function c() { return f() }
Need an “HTS” language compiler that turns:
type NoAny = <X, Fallback> => { if (X === any) return Fallback return X } Into: type NoAny<X, Fallback> = 0 extends (1 & X) ? Fallback : X
- 帖子
- 62
- 内容占比
- 31.0%
- 点赞中位数
- 178.5
- 最高表现
- 8.3×
前端开源库与工具发布
COBE v2: reliably use any DOM elements as markers & arcs. CSS transition, animation, filter, interactivity, ...all just work.
High perf, zero deps, still ~5KB. Coming soon.
I trained a small model to do syntax highlighting in the browser with GPU.
Meet gpu-lexer from Vercel Labs: Small (27.5KB), fast (runs on WebGPU), and language-agnostic (model guesses the syntax). https://t.co/adphvt2Lv4 It is experimental and built for learning!
COBE v2 is here: markers, arcs, attach any HTML elements, Infinite ideas.
https://t.co/JBRZeS4dKw
Better Promise.all with automatic dependency optimization and full type inference:
https://t.co/b59k7xQnd6
图片加载中…Made `bidc` — create bidirectional message channels between different JavaScript contexts (main document, worker, iframe, service worker, etc.):
https://t.co/L2Yyi6A8qT
Made `nstr` — Stringify numbers in JavaScript with smart precision detection. No more ugly precision issues in your UI:
𝚌𝚘𝚗𝚜𝚝 𝚙𝚛𝚒𝚌𝚎 = 𝟷𝟿.𝟿, 𝚛𝚊𝚝𝚎 = 𝟷𝟶𝟶 𝚛𝚎𝚝𝚞𝚛𝚗 <𝚜𝚙𝚊𝚗>${𝚙𝚛𝚒𝚌𝚎 * 𝚛𝚊𝚝𝚎}</𝚜𝚙𝚊𝚗> Shows: $1989.9999999999998 instead of $1990 😱 https://t.co/LA9faf1e4r
Next version of Satori:
grid/block/inline/inline-block, fixed/sticky, float/clear, list-style, counter, word-spacing, overflow, aspect-ratio, order, visibility, outline, mix-blend-mode, isolation, paint-order, z-index, 3D transform, conic gradient, calc(), min/max/clamp() https://t.co/rH2QtKv7wS
After one week, there are 5 more small models for specific tasks on the web:
1. gpu-time: natural language to JS date and time by @imarikchakma 2. gpu-query: natural language to structured filters by @cheatyyyy 3. neural-flexbox: model to centre a div (!) by @aaronvanston 4. gpu-cron: natural language to cron expressions by @ManuSchiller 5. tinysarf: arabic morphological analyzers by @Ahmedabdou1996
In the latest `swr@beta`, you can seamlessly move data fetching between client-side and server-side, or both, in an RSC framework like Next.js:
🔸Client only: useSWR(key, fetcher) 🔹Mixed: useSWR(key, fetcher) + RSC-provided data 🔸Server only: useSWR(key) + RSC-provided data https://t.co/UOqZ8XXEh2
Thanks to our contributors, next-view-transitions v0.3.2 is now released with several improvements: 🔸 New useRouter equivalent API: useTransitionRouter 🔸 Fix page stuck caused by hash changes 🔸 Fix browser fallback
Releases: https://t.co/HVTkwbU56C https://t.co/wF4SMHAHh7
In the next version of Next.js Image Generation: - Sharp for rendering - Faster Satori core - background-size: cover, contain, auto - text-decoration-skip-ink
Same ImageResponse, 65% faster:
图片加载中…Some recent updates to @vercel’s Satori library:
- text-wrap: "pretty" - text-decoration-style: double - pointScaleFactor - Async components - Memory and speed improvements https://t.co/SLmGvcjDmZ
Some big feature updates for Satori. More in thread. Coming soon to Next.js ImageResponse:
• HarfBuzz text shaper (YES!) • WebP as image source • backdrop-filter • shape() in clip-path • corner-shape https://t.co/SLmGvcjDmZ
Retrained GPU Lexer (https://t.co/ELWO2Qtu0J) and published v0.0.5. Top 25 weighted language accuracy increased from 86.77% to 92.20% now: https://t.co/buskgcUa1c
图片加载中…The new React Wrap Balancer 1.0 version now uses the native CSS feature `text-wrap: balance` automatically when it’s available!
Read more about the release: https://t.co/VILrGj95Ge CSS `text-wrap: balance`: https://t.co/iDqKQaqmDD https://t.co/eP3Rtfx2KF
Made `legid` — a library for generating safe, legit and random URL-safe IDs:
https://t.co/Cw8sAdg9hI
Some recent updates for @vercel’s OG image generation and Satori:
🔹 Flex gap is now supported 🎉 🔹 HTML lang= attr 🎉 🔹 currentColor 🎉 🔹 Improvements related to emojis, viewBox, data URI, break-word, white-space and more https://t.co/u6flVtDBfE https://t.co/PjbaxQigYW
Got a lot of attention for this (thank you!), but also there're some criticisms and questions:
1) it's a stupid idea Maybe. Again, this is experimental and not meant to be used in production or as a replacement for anything. It is to explore new possibilities. 2) it's unnecessary and sometimes wrong Existing solutions are not always more correct just because they're "algorithmic". For example pic 1 is Highlight.js and 2 is gpu-lexer, lang is JS not something rare. There are counterexamples too. Furthermore, language-agnostic is the real reason for exploring this approach. During training, the neural network learned patterns like "[keyword] variable = value" that are not tied to any specific programming language such as: var ... = ... let ... = ... const ... = ... using ... = ... val ... = ... auto ... = ... type ... = ... def ... = ... And that knowledge can be shared without re-implementing a grammar rule repeatedly. Another advantage is that this approach can potentially generalize to new programming languages or dialects without requiring extensive manual rule creation. If you go to https://t.co/s92Q3d2w94, you can't find popular Web framework languages like Vue, Svelte, Astro, and many others. Not to mention that new languages and dialects are constantly emerging, making it impractical to maintain comprehensive grammar rules for all of them. When that's a concern, you either use more comprehensive solutions like Shiki with a cost (carefully bundle, detect and load language definitions on demand, larger size), or use an easier approach for all kinds of source code with another cost (less accurate). That is definitely a good reason to explore this direction.
图片加载中…Optimized https://t.co/ELWO2Qtu0J to be 3.8x faster: 850ms → 221ms. It's still far behind @pierrecomputer's https://t.co/Ft4edFyyZX (incredible work!)
Also wrote down some thoughts on https://t.co/FW2Hu9LDtL https://t.co/B20ThWR5Qr
图片加载中…What if there’s a <Satori> component that adds fluid layout & style transitions to your elements? https://t.co/E0pMeIr8ry
Satori v0.16.0 (thanks to @yogalayout):
New features: - box-sizing - display: contents - position: static Improvements: - Bugfixes for absolute positioning - Support percentage values for flex gap - Smaller package size https://t.co/SLmGvcjDmZ
Adding `text-wrap: balance` to Satori, cc @lachlanjc @andrewingram https://t.co/9KMj6zj8Ij
Tip: you can use “advanced” CSS features like `mask-image` and `text-wrap: balance` in Satori and @vercel/og.
Very helpful for social cards! https://t.co/1MqsJvguHm https://t.co/amHXu7C7bw
图片加载中…Not 100% yet but I'm very proud of SWR’s test coverage: https://t.co/vHfZyHJyoM
图片加载中…Satori (https://t.co/gKt6wPKylc) recently added: - tab & tab-size - line-clamp with ellipsis - clip-path - improved HSL syntax - improved radial-gradient & linear-gradient - multiple text-shadow
Can’t thank enough to our contributors @LuQinYan, https://t.co/bRMfvkJfQQ!
Latest SWR (v2.3.8) comes with:
- A new `strictServerPrefetchWarning` option to let you progressively embrace the “prefetch on the server” pattern for better performance: https://t.co/VVXrPB9TUQ - Better TSDoc with tons of new code examples https://t.co/DCoXTZi9KJ
图片加载中…- 帖子
- 41
- 内容占比
- 20.5%
- 点赞中位数
- 295
- 最高表现
- 17.9×
CSS 与 Web 渲染实验
Depth-based blur in CSS.
https://t.co/kB7gFdbh5k (Chrome preferred) https://t.co/W3RPVgh799
图片加载中…UI and math time! UI = f(props) is the most famous line in React. But that f is JavaScript, not math.
Inspired by @_chenglou’s Handwired project, I compiled a <Dashboard/> component into a real math function, and asked what becomes possible. https://t.co/huyWUwLCpx
Let there be light https://t.co/IeaEHKC7uU
There’s a trend of using rotating gradients as input / button borders with CSS. Here’s a neat trick to enhance its appearance: https://t.co/DvPg8hvcIm
HTML/CSS is Turing complete, so why not compile programs to plain HTML/CSS and runs with zero bytes of JavaScript?
https://t.co/VIIgOoUs9P https://t.co/goMiXFVom6
There’s an idea that I’ve been casually working on for quite a while: bringing shaders to React.
Here’s my first demo: https://t.co/oyygjLlIeQ
CSS-only scroll area indicator using `scroll-timeline`.
The trick is to simply add an opacity animation, controlled by that timeline, to these 2 arrow elements. https://t.co/38X9SsaJka https://t.co/JY4TVTk6tX
shaduocn sidebar: https://t.co/ZDL6LjeqJ1 https://t.co/fT29l5GetM
Sorry but here’s a snippet to add that to any website:
https://t.co/ilXLnNiRow https://t.co/kbYlMXPZkf
Write simple shaders for HTML elements (Chrome only): https://t.co/UldXOFFNE3 https://t.co/Cxs9g8oHDs
Another CSS-only toy: Color Picker. Built with 790 `:has()` selectors.
https://t.co/UpBlxbCOMO https://t.co/SCWzpkuxg1
Guess I really love CSS and I’m obsessed with the idea of CSS-only challenges. There are some interesting tricks used and someday I’ll write about them...
Here are a few of them:
Double-slit experiment in JavaScript: a single rule about console.log() produces a zoo of quantum phenomena.
which( function path1() { return 0 }, function path2() { return 1 }, ) // → 0.5 https://t.co/yVoh5WPP4b
Liquid glass was cute. Here’s liquid diamond: https://t.co/qKT5PglnfL
Going to convert markers of https://t.co/GzD8ceTH0C to attributes of a new vertex shader. This works similar to a particle system, and it is more performant than the for loop in our current fragment shader (so you can add more markers!).
Next is arcs and DOM nodes/events. https://t.co/NW0wZhSjPg
For those who love the idea of Zero JS: use <textarea> and CSS container query to make interactive sliders!
https://t.co/n5MC0V2NVF https://t.co/Gc9wJ9xP8y
Tailwind CSS is a good abstraction.
Sunday night CSS toy https://t.co/iYBUAWw1Qg
Ported some of my generative visuals to React Native w/ @expo two years ago. Maybe this year I can make some progress… the “N connected sliders start from any point” interaction was clean and joyful :D https://t.co/lwvyhqhxEk
Quick CSS tip: you can use word-spacing, text-transform and ::first-letter to turn English into German https://t.co/4lOYJsFoEO
Here’s a list of CSS challenges I’ve been casually thinking about so far... very fun :D https://t.co/G7FNlcmsiA
图片加载中…After making https://t.co/GzD8ceUeQa I found that on Chrome, using requestAnimationFrame and CSS3 animations together will trigger style recalcs on every frame: https://t.co/byCehRE3IV.
Might be something to work around especially for WebGL sites.
There might be two dimensions, one is about machine and the other is about mind
Atomic styles vs bundled styles Inline styles vs multi-hop styles
- 帖子
- 34
- 内容占比
- 17.0%
- 点赞中位数
- 284
- 最高表现
- 26.6×
AI 辅助开发与产品动态
Tell your agent to optimize your site’s web fonts. I’m seeing a huge difference on my blog.
Full prompt: Make this site's web fonts load faster without changing how anything looks. Shrink font bytes as far as possible, keep rendering identical, and prove it with before/after pixel diffs. Treat any visual change as a regression unless I approve it. If an optimization would change rendering, tell me what it saves and what it changes, and keep the site looking the same by default. Keep the current loading behavior: don't touch font-display or fallback fonts. Don't add font processing to the build; write a script I run by hand, commit its output, and note when it needs rerunning. First measure the current state: each font file's size, glyph count, variable axes, OpenType features and hinting, plus font bytes per page and what each page preloads. Then find out what the site actually uses, checking inline component styles as well as stylesheets: which characters appear in the content, which axis values and weights each font needs (including one-off overrides and bold inside italics), which OpenType features are turned on, and CSS side effects like `hyphens: auto` using the U+2010 hyphen. Cut each font down to that. Keep the used characters plus Latin-1 and Latin Extended-A, and leave CJK to system fonts if that's how it renders today. Limit variable axes to the ranges in use, and only fix an axis at one value if nothing overrides it. Drop unused OpenType features and hinting. Split each font into two files. A small core with ASCII and the punctuation most pages use (curly quotes, dashes, ellipsis) gets preloaded. An extended file behind `unicode-range` only downloads when a page needs one of its characters. Each file's `unicode-range` should list only characters it actually contains. Watch out for a few things. A generated fallback face between the core and extended files will draw the extended characters before the real font does. Fonts with a Reserved Font Name under the OFL must be renamed internally once subset. Check the generated files, since font tools have quirks. Before calling it done, build a baseline from the same content and pixel-diff before and after on pages with code, italics, accented characters, components with their own font settings, and CJK. Explain every visible difference: content change, regression to fix, or harmless sub-pixel rounding. Re-measure bytes per page and confirm the extended files only load where needed. When you're done, tell me the bytes before and after per font and per page, the pixel-diff results, anywhere you deviated from what I asked and what it cost, and how to rerun the script. Later, it may be worth embedding the core font in the global stylesheet and precaching the extended files after idle.
图片加载中…I need this specific tool,
before: All top 10 Google results are not handy enough now: Just ask @v0 to build it https://t.co/AUHKjWSMN5 https://t.co/kGXSa2N5Sj
图片加载中…Needed to add magnifier effect to a screenshot, so I built this tool with @v0 in 20 minutes: https://t.co/E7CfFcJqwS
Chat: https://t.co/md81fX0RPD Repo: https://t.co/ovApgeDyW7 https://t.co/a4xUvSSSWj
I love shaders but they usually take a lot of time to tweak. It unfortunately makes me less motivated to create.
But recently @v0 is my superpower and encourages me to create more without hesitating. Even a 5 minute gap before sleep: https://t.co/Ytb9Q4espP https://t.co/ChzXhUmypy
import { useChat } from 'ai/react'
https://t.co/XXKTc2Cu87
Some @v0 Design Mode tips:
1. Double click to edit text https://t.co/mWZ7DqAvLG
Vercel AI SDK, Next.js & Nextra, Cobe, SWR on one picture 🥁
https://t.co/UiXiHrGp2U https://t.co/0DJk1y906o
图片加载中…Created an interactive macOS dock in 1min using https://t.co/zsRX0cmo66. https://t.co/LYZakKF2Fo
Now https://t.co/zsRX0cmo66 is out, I can share one of my early @vercel internal demos created back in March. https://t.co/i7yg77WfSe
This @vercel feature is underrated: https://t.co/Q2E3d6XGIk
图片加载中…We’ve improved the load time of @v0’s generations significantly. See the before/after difference: https://t.co/91aOlMbZzd
Copy prompt is the new `npm i <pkg>` for your docs (https://t.co/GzD8ceUeQa). https://t.co/Vae64aD7is
图片加载中…Wanted to show IO waterfall impacts in server-client apps (https://t.co/1spONUGaTJ). With 1 prompt, it was joyful to see @v0 one-shot this visualization with agent-browser:
1. Screenshotted the WIP 2. Identified issues and ran browser scripts for more info 3. Patched fixes and re-screenshotted to verify
图片加载中…Image to code was achieved internally 5 years ago
https://t.co/VSz72VBeqV https://t.co/ro9i8aecwq
图片加载中…LLM-powered apps have longer request/session durations. Common to see >30s streamed requests.
With around 24*60*60/30 = 2,880 daily requests globally (distributed evenly), you can’t just cd into your server and restart your app anytime. It will break some users.
Some personal thoughts and notes from a while back about the architectural design of AI tools. And I guess AutoGPT now already implements something similar, even with long-term memory. https://t.co/GwYUu7GSUe
图片加载中…- 帖子
- 28
- 内容占比
- 14.0%
- 点赞中位数
- 231.5
- 最高表现
- 8.6×
技术随笔与个人思考
My 10 years on GitHub https://t.co/9dWugCHtUN
图片加载中…13 years ago, Apple asked a question that hits me harder today than ever:
If everyone is busy making everything, how can anyone perfect anything? Every day, I see a world flooded with effortless AI slops. I’m realizing that to build something truly great today, you need a level of focus the world has never demanded before. It feels like trying to write a quiet, beautiful song in a room full of loud noise.
Best book I read this year! https://t.co/BaFLSDSW8r
图片加载中…5 years, glad that we’ve made something https://t.co/t1Ifjf0DP7
图片加载中…I spent a month in NYC & SF preparing for the launch of https://t.co/zsRX0cmo66 with the team — it went smoothly. On the night of release, while flying back to Europe, I was treated to a stunning aurora over the Greenland skies. Breathtaking. https://t.co/dVD8UotiJc
图片加载中…Miss the old days of open source. Code carried a piece of its maker. Software made with <3.
Perfect Days https://t.co/geiUPcNAMY
图片加载中…Use the platform (nah) https://t.co/wdf030wpG2
图片加载中…Books that keep coming back to me https://t.co/iPx4oZbtQ1
图片加载中…You can just ship things.
https://t.co/yh4ynHOxlF https://t.co/JUIEziZo4G
“Give people wonderful tools, and they’ll do wonderful things.”
I put some of my random notes into a blog post:
https://t.co/PcfNWTid9E
Take a rest and have a great weekend. https://t.co/Gp143fvr8n
图片加载中…Reading a book about Fermat’s Last Theorem and I can’t stop thinking about this: a good conjecture is sometimes more valuable than the proof.
Good taste is about solving problems. Great taste is about identifying them.
Wrote a new post based on some of my recent thoughts...
https://t.co/kgtXM36jcs
“And what do you think was the salient feature of the rainbow that inspired Descartes’ mathematical analysis?”
[…] “I would say his inspiration was that he thought rainbows were beautiful.” https://t.co/Qdp7kNPLw7
图片加载中…- 帖子
- 19
- 内容占比
- 9.5%
- 点赞中位数
- 246
- 最高表现
- 43.1×
其他
https://t.co/9TB5cxo6m3
https://t.co/5KO6Eh65Qu
图片加载中…https://t.co/8mV27S4KD6
This might be helpful: https://t.co/CxtSBhHDzS https://t.co/aiGYZKdI8J
https://t.co/dN1yGK1xxZ https://t.co/H7L5yrD3ga
图片加载中…Got my Next.js conf ticket (sorry designer friends edition)
https://t.co/UgDw3BwqX3
https://t.co/YwHg7WWDP1
https://t.co/jJMc1BUIKH
图片加载中…https://t.co/iyz8VRpvEm
图片加载中…- 帖子
- 16
- 内容占比
- 8.0%
- 点赞中位数
- 108.5
- 最高表现
- 7.8×
账号定位
Vercel 工程师的个人技术账号,围绕前端框架、React/Next.js 生态、CSS 与 Web 渲染技术分享工程实践、开源库与可视化实验。
内容策略
以第一人称发布技术更新与自研工具(Satori、SWR、COBE、gpu-lexer 等),结合代码片段、演示视频和博客链接讲解原理;同时转发/点评团队产品进展与前端设计思考,形成开发者社区影响力。
核心判断
Shu(@shuding)的 X 账号本质上是一个“个人技术品牌、Vercel 生态分发和创意 R&D 日志”的三合一账号。它不依赖高频评论热点,而靠可验证的 demo、框架内部知识、产品更新和个人审美建立信任,再把信任转化为对 Next.js、Satori、v0、SWR、UI SDK 等产品的关注与采用。
用一句话概括:用“个人实验室”的方式,把 Vercel 生态的技术进展包装成高信号、可视化、可传播的内容。
一、账号定位:不是官方号,而是“高信号个人实验室”
- 身份标签清晰:@vercel、前端框架/工具作者、开源维护者、创意编程爱好者。
- Bio 是 “Don’t talk unless you can improve the silence.”,与内容风格高度一致:少说、给结果、用作品证明。
- 他同时扮演三种角色:
- 产品布道者:发布 Next.js、SWR、Satori、v0、UI SDK 的更新;
- 工程解释者:把 RSC、Server Actions、缓存、编译器等讲成心智模型;
- 创意开发者:做 CSS-only 玩具、shader、3D、GPU 小模型等“非必要但很吸引人”的实验。
这种定位比纯官方号更有“人味”,也比纯个人号更有产品分发能力。
二、内容矩阵:五类内容,各承担不同任务
| 内容类型 | 典型内容 | 策略作用 | 数据特征 |
|---|---|---|---|
| 产品/版本发布 | Next.js typed routes、Server Actions、SWR beta、Satori v0.16、ImageResponse 提速、v0、UI SDK | 把 changelog 变成有场景的新闻;用视频/前后对比降低理解成本 | 稳定中高互动,带视频和明确收益的帖子更容易起量 |
| 技术深潜/心智模型 | RSC 与 gSSP/gSP 对比、use cache、Server Actions 原理、“Dynamism starts at reading the data” | 建立专家权威;吸引高价值开发者收藏 | 浏览不一定最高,但收藏/转发率高 |
| 视觉 demo/创意编程 | depth-based blur、CSS-only scroll indicator、liquid glass、COBE、shader、gpu-lexer | 破圈拉新;用“哇”效果制造传播 | 最容易出大爆款,点赞和浏览显著高于均值 |
| 开源工具/库 | bidc、nstr、better-all、legid、next-view-transitions | 展示 builder 身份;导流 GitHub 和文档 | 收藏率高,适合沉淀长期资产 |
| 观点/策展/个人 | GitHub 10 年、Apple 广告引用、AI slop、书单、极光、Perfect Days | 人格化;提供情绪共鸣和价值观表达 | 偶发高传播,尤其涉及开发者身份和时代情绪 |
整体看,视觉演示和技术解释是账号的两大引擎;产品发布是落点;个人内容负责让账号不变成冷冰冰的公告板。
三、叙事公式:Demo 先行,原理解释,产品落地
Shu 的多数高表现帖子遵循一个很稳定的结构:
- 一句钩子:如 “Depth-based blur in CSS.”、“Let there be light”、“COBE v2 is here”;
- 视觉证据:视频、动图、截图、before/after;
- 技术点或量化收益:如 “2x faster”“~5KB”“790 个
:has()选择器”; - 产品/库/文章链接:把兴趣导向 Next.js、Satori、v0 或 GitHub。
例如:
- “Depth-based blur in CSS” 用一句极短文案 + 视觉 demo,拿到约 154 万浏览、6,220 点赞;
- COBE v2 先发“coming soon”预告,再发正式发布,形成连续叙事;
- gpu-lexer 用“小模型 + WebGPU + 27.5KB”制造反差,拿到约 80 万浏览;
- “Building Bulletproof React Components” 用长文/清单承接,收藏接近 2,000,说明工具型内容有很强的沉淀价值。
短文案不是没信息,而是把信息压缩进媒体和链接里。长文则是例外,主要用于建立心智模型和权威。
四、分发机制:个人号作为 Vercel 的“人味分发层”
几个关键策略:
-
员工 advocacy / 创始人式布道
用个人账号发产品更新,比品牌号更可信、更容易进入开发者时间线。 -
Dogfooding
用 v0 做 demo、用 Satori 做图像、用 UI SDK 做 themed components,产品既是工作对象,也是内容素材。内容因此不是“转述”,而是“我用它做出来了”。 -
连载与预告
COBE v2、gpu-lexer 版本迭代、UI SDK behaviors、Satori 更新都是连续剧式内容,培养期待感。 -
社区互惠
感谢 contributor、cc 合作者、转发他人项目、强调 OSS 生态。这既塑造开源形象,也激活网络分发。 -
事件驱动,而非日更
内容集中在发布、会议、side project、技术争议之后,频率不算高,但每次都有“由头”。
五、数据表现:高浏览靠视觉,高收藏靠工具,高共鸣靠身份
从样本中的爆款看,三类内容最容易出圈:
- 视觉奇观:depth blur(154 万浏览)、COBE v2(22.6 万浏览)、gpu-lexer(80 万浏览);
- 开发者身份/时代情绪:GitHub 10 年(103 万浏览、1 万点赞)、Apple “perfect anything” 引用(16 万浏览、4,345 点赞);
- 可操作的高价值内容:font optimization prompt(16 万浏览、3,330 收藏)、“Building Bulletproof React Components”(11 万浏览、1,975 收藏)。
而 RSC 心智模型、use cache、Server Actions 图解这类内容,浏览不如视觉 demo,但收藏/转发比更高,说明它们承担的是“专业信任”和“长期参考”职能。
一个值得注意的特征是:回复数相对浏览数普遍偏低。这说明账号更像广播型专家号,而不是强互动社区号;价值主要体现在收藏、转发和产品采用,而不是评论区热闹。
六、优势与风险
优势:
- 真实、可验证,几乎每条重要内容都有 demo、数据或代码支撑;
- 品效合一:既能做品牌人格化,又能直接导流产品、文档和 GitHub;
- 跨圈层:框架工程师、CSS 爱好者、AI 工具用户、设计师都能找到入口;
- 长期复利:技术深潜和工具库内容会持续被收藏、搜索和引用。
风险:
- 主题跨度大:Next.js 内部机制、CSS 艺术、AI 模型、书单、生活内容混在一起,新访客可能不容易快速理解账号主线;
- 极简/链接帖较多:对老粉是“高信号”,对新用户可能缺少上下文;
- 产品关联强:如果发布类内容过密,可能被感知为营销号;
- 个人依赖度高:账号价值高度绑定 Shu 本人的技术判断和审美。
七、可优化的方向
- 栏目化:用固定标签区分 Release / Deep Dive / Demo / Note,让新用户一眼看懂内容结构。
- 给 demo 补一句“why it matters”:视觉已经足够强,再加一句“这解决了什么”会提升转化。
- 把爆款系列化:CSS-only challenges、GPU 小模型、UI SDK behaviors 都可以做成连续栏目。
- 长文二次分发:技术长文拆成 thread、图卡、短视频,延长生命周期。
- 减少无上下文链接帖:至少加一句 takeaway,避免只有 insider 能读懂。
- 按目标看数据:拉新看浏览/点赞,专业信任看收藏/转发,产品采用看点击和安装,不要用同一套指标衡量所有内容。
总结: Shu 的内容策略不是“多发文”,而是“用作品说话”。他把工程能力、产品路线和个人好奇心压缩成高密度内容,让个人账号成为 Vercel 生态最有效的开发者触点之一。最值得借鉴的不是某一条爆款,而是这套**“可验证的 demo → 技术解释 → 产品落地 → 社区复用”**的闭环。
表现总览
Shu 的内容支柱有哪些,表现如何?
内容支柱是账号持续发布的核心主题。 Shu的主要内容支柱包括React 与 Next.js 框架实践、前端开源库与工具发布和CSS 与 Web 渲染实验。
左边是发帖占比,右边是点赞占比;右侧方框是单篇平均表现相对账号平均值的倍数,越高代表单篇平均表现越好。
Shu 的主要内容支柱是「React 与 Next.js 框架实践」,占发布内容的 31.0%。 围绕 React Server Components、Server Actions、Next.js App Router、类型化路由、构建与渲染性能等框架机制与工程实践的分享。 例如:I wrote a blog post: Building Bulletproof React Components: https://t.co/xWD215↗,2026-02-06 发布,获得 1.94K 点赞(8.3×)。
Shu 表现突出的内容支柱是「技术随笔与个人思考」:以 9.5% 的发布占比贡献 19.5% 的点赞,单帖平均点赞为账号平均水平的 2.1 倍。 关于开源文化、设计品味、阅读、工作生活片段等非技术性个人表达与观点。 例如:My 10 years on GitHub https://t.co/9dWugCHtUN↗,2023-01-02 发布,获得 10.1K 点赞(43.1×)。
Shu的帖子表现如何随时间变化?
Shu的点赞高点出现在2023年1月2日和2023年6月18日,对应原帖见图下。
每个点代表一篇帖子,越靠右发布时间越近,越高代表指标越高。
点赞最高的帖子: My 10 years on GitHub↗· 10.1K(43.1× 中位数) · Depth-based blur in CSS. (Chrome preferred)↗· 6.22K(26.6× 中位数)
Shu的内容形式表现有什么不同?
引用转发是Shu发布最多的内容形式,占发布量的39.5%。
横轴是每篇帖子的点赞表现,越往右表现越好;柱子越高,帖子越多。
视频的单帖平均点赞约为图片的1.21倍。 视频的单帖点赞中位数约为图片的1.82倍。
例如:COBE v2: reliably use any DOM elements as markers & arcs. CSS transition, animat↗,2026年3月15日 发布,获得 4.19K 点赞(17.9×)。
例如:My 10 years on GitHub↗,2023年1月2日 发布,获得 10.1K 点赞(43.1×)。
Shu哪些帖子明显超过日常表现?
Shu表现最高的帖子获得10,076点赞,为账号单帖中位数的43.1倍。
排名前5%的帖子贡献了37.5%的点赞。
My 10 years on GitHub ↗ · 10,076 点赞 · 43.1× 单帖中位数
Depth-based blur in CSS. (Chrome preferred) ↗ · 6,220 点赞 · 26.6× 单帖中位数
Shu 的浏览量与互动率
Shu 浏览量最高与浏览互动率最高的是不同帖子。
横轴浏览量,纵轴互动率;对数刻度,中位数分区 · 200 条成对已知数据 · 点面积表示帖子数,悬停预览,点击固定
Shu帖子中的常见词语与短语
双词短语模式中,server components、app router、image generation和react server出现最多。
;;;
词云
按含词帖子数 · 200 篇 · 0 / 100 词时间分析
Shu 在 X 的发布日历
2023/01/02— 2026/11/26· 204周Shu 在9月18日发布最集中,当天发布 3 篇。
9月18日发布 3 篇,是当前日期范围内发布量最多的一天。 当天点赞最高的帖子获得 497 次点赞。 查看原帖 ↗
Shu 在有发布的日期平均每天发布 1.1 篇;按2023年1月2日–2026年11月26日整个日期范围计算,平均每周发布 1 篇。
Shu的帖子表现如何随时间变化?
Shu的点赞高点出现在2023年1月2日和2023年6月18日,对应原帖见图下。
每个点代表一篇帖子,越靠右发布时间越近,越高代表指标越高。
点赞最高的帖子: My 10 years on GitHub↗· 10.1K(43.1× 中位数) · Depth-based blur in CSS. (Chrome preferred)↗· 6.22K(26.6× 中位数)
Shu 在 X 的最佳发布时间
Shu 的点赞中位数最高的发布窗口是周日 00:00–04:00 UTC。
UTC · 每 4 小时一组 · 格内数值与颜色深浅表示单帖点赞中位数,悬停查看样本数 · 200 条精确时间数据
Shu 点赞中位数最高的发布窗口是周日 00:00–04:00 UTC:点赞中位数为 1,176.5,有 6 条帖子的点赞数据。 查看代表原帖 ↗
Shu 每周的发布量与点赞表现
1月16日–1月22日发布量最高,为 5 篇;1月2日–1月8日的点赞中位数最高,对应 1 篇帖子。
UTC 自然周 · 上:发帖数;下:单帖点赞中位数(采集时累计值)· 悬停查看日期和样本数
Shu 各内容支柱的点赞如何随发布进程变化?
1月2日–4月11日这一组以“技术随笔与个人思考”的点赞最多;紧接着4月11日–7月13日这一组,“CSS 与 Web 渲染实验”的点赞最多。
按相邻约 20 条帖子分组,同一时间点保留在一组 · 每格为已知点赞总量,日期为该组实际范围
关于Shu内容策略的常见问题
Shu哪条帖子的点赞最多?
点赞最高的帖子获得10,076次点赞,约为Shu单帖点赞中位数的43.1倍。
这篇帖子发布于2023年1月2日,原文写道:“My 10 years on GitHub”。
查看原帖 ↗Shu最常发布什么形式,视频和图片表现有什么差别?
引用是Shu最常发布的形式,占39.5%。
按单帖平均浏览量比较,视频约为图片的1.13倍;按浏览量中位数比较,视频约为图片的1.62倍。
查看内容形式 ↗Shu在X的发布频率是多少?
在这份报告覆盖的日期范围内,Shu平均每周发布约1.0条内容。
Shu最常在周日(36篇)和周五(34篇)发布。
发布最集中的一天是2023年9月18日,当天发布了3篇。
查看发布日历 ↗


















