惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

美团技术团队
T
The Exploit Database - CXSecurity.com
aimingoo的专栏
aimingoo的专栏
小众软件
小众软件
T
Tailwind CSS Blog
V
V2EX
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
WordPress大学
WordPress大学
Hugging Face - Blog
Hugging Face - Blog
IT之家
IT之家
PCI Perspectives
PCI Perspectives
腾讯CDC
酷 壳 – CoolShell
酷 壳 – CoolShell
Recent Commits to openclaw:main
Recent Commits to openclaw:main
大猫的无限游戏
大猫的无限游戏
The Cloudflare Blog
N
News and Events Feed by Topic
博客园 - 三生石上(FineUI控件)
Help Net Security
Help Net Security
雷峰网
雷峰网
有赞技术团队
有赞技术团队
Last Week in AI
Last Week in AI
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
量子位
GbyAI
GbyAI
O
OpenAI News
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
AI
AI
S
Security Affairs
F
Fortinet All Blogs
L
LINUX DO - 最新话题
博客园 - 【当耐特】
Webroot Blog
Webroot Blog
Schneier on Security
Schneier on Security
W
WeLiveSecurity
Security Latest
Security Latest
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
T
Tenable Blog
L
LINUX DO - 热门话题
Google DeepMind News
Google DeepMind News
Simon Willison's Weblog
Simon Willison's Weblog
Cyberwarzone
Cyberwarzone
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
C
CERT Recently Published Vulnerability Notes
Engineering at Meta
Engineering at Meta
P
Palo Alto Networks Blog
博客园 - 叶小钗
T
Threatpost
H
Heimdal Security Blog
Microsoft Security Blog
Microsoft Security Blog

Kent C. Dodds Blog

Implementing Hybrid Semantic + Lexical Search Simplifying Containers with Cloudflare Sandboxes Migrating to Workspaces and Nx Offloading FFmpeg with Cloudflare Building Semantic Search on my Content Helping YOU ask ME questions with AI How I used Cursor to Migrate Frameworks The Dow's Start on the Covenant Path 2025 in Review The next chapter: EpicAI.pro AI is taking your job How I increased my visibility Launching Epic Web 2023 in Review Stop Being a Junior RSC with Dan Abramov and Joe Savona Live Stream Fixing a Memory Leak in a Production Node.js App 2022 in Review My Car Accident I Migrated from a Postgres Cluster to Distributed SQLite with LiteFS I'm building EpicWeb.dev A review of my time at Remix Remix: The Yang to React's Yin How I help you build better websites Why I Love Remix The State Initializer Pattern How to React ⚛️ Get a catch block error message with TypeScript Building an awesome image loading experience How Remix makes CSS clashes predictable Introducing the new kentcdodds.com How I built a modern website in 2021 How to use React Context effectively Static vs Unit vs Integration vs E2E Testing for Frontend Apps The Testing Trophy and Testing Classifications Array reduce vs chaining vs for loop Don't Solve Problems, Eliminate Them Super Simple Start to Remix Super Simple Start to ESModules in Node.js JavaScript Pass By Value Function Parameters How to write a Constrained Identity Function (CIF) in TypeScript How to optimize your context value How to write a React Component in TypeScript TypeScript Function Syntaxes Listify a JavaScript Array Build vs Buy: Component Libraries edition Using fetch with TypeScript Wrapping React.useState with TypeScript Define function overload types with TypeScript 2020 in Review Business and Engineering alignment Hi, thanks for reaching out to me 👋 useEffect vs useLayoutEffect Super simple start to Firebase functions Super simple start to Netlify functions Super Simple Start to css variables Favor Progress Over Pride in Open Source Testing Implementation Details How getting into Open Source has been awesome for me useState lazy initialization and function updates Use ternaries rather than && in JSX Application State Management with React Use react-error-boundary to handle errors in React JavaScript to Know for React How I structure Express apps What open source project should I contribute to? When I follow TDD AHA Programming 💡 How I Record Educational Videos Should I write a test or fix a bug? Stop mocking fetch Intentional Career Building Improve test error messages of your abstractions Tracing user interactions with React Eliminate an entire category of bugs with a few simple tools Common mistakes with React Testing Library Super Simple Start to React Stop using client-side route redirects The State Reducer Pattern with React Hooks Function forms Replace axios with a simple custom fetch wrapper How to test custom React hooks React Production Performance Monitoring Should I useState or useReducer? Stop using isLoading booleans Make Your Test Fail Make your own DevTools An Argument for Automation Fix the "not wrapped in act(...)" warning Super Simple Start to ESModules in the Browser Implementing a simple state machine library in JavaScript 2010s Decade in Review Why users care about how you write code Why I avoid nesting closures Don't call a React function component Why your team needs TestingJavaScript.com Inversion of Control Understanding React's key prop How to Enable React Concurrent Mode Profile a React App for Performance
🏎 downshift 2.0.0 released 🎉
2018-06-15 · via Kent C. Dodds Blog

Even better accessibility, React Native and ReasonReact support, even simpler API, improved docs, new examples site, Flow and TypeScript support, and a new online community ⚛️

I'm excited to let the world know that downshift 2.0.0 has been released! So I'm going to do it now:

Hey world! downshift 2.0.0 has been released!

Woo! So what do you have to look forward to? Let's dive in! (If you haven't heard of downshift, consider reading the original release post).

Improved Accessibility (#a11y)

Lead primarily by Michael Ball (with helpful reviews from several others), we received a number of improvements to the accessibility features baked-into downshift. He also added a new getMenuProps prop getter (which was also instrumental in fixing a bug with React Portals). This allows us to add some aria- attributes to the menu you render that will help assistive technologies use your enhanced input components! Woo! I've also updated many of the examples to use more semantically correct elements.

React Native Support

We've actually had this for a while in 1.x, but I wanted to include this in the blog post because there was never really an official announcement and I think that this is great! This is largely thanks to work by Eli Perkins! They've already shipped downshift to production in their iOS app:

Screenshot of downshift code in React Native from Eli

ReasonReact Support

We've actually had this for a while too, but I want to call it out especially. Thanks to Nicola Molinari there are official Reason bindings for downshift. So you can build UIs for any platform you can imagine with downshift and ReasonML. Soooo cool!

Simpler API

It's generally a good idea to avoid APIs which allow two ways to do the same thing. It's just another thing to list in docs, and you have to help people understand what the differences are (if there are any).

Up until downshift 2.0.0, we had two props that could be used for your render prop: render and children. Then React released the official context API which uses render props and they called it children. In an effort to develop consistency throughout the ecosystem, we've dropped the prop called render and now only support children.

Improved Docs

After downshift was out for a while, I started to realize that folks missed out on some of the more useful and necessary props (like itemToString). I blame myself for this and recently reorganized the docs to make more relevant information more apparent.

New Examples Site

It's just getting started (so there are only a few examples), but it's here and ready for contributions!

Find it and contribute (right in the browser!) on codesandbox!

The codesandbox for the examples site

Improved TypeScript Support

A great effort lead primarily by @stereobooster has lead to improved TypeScript definitions for downshift. Even if you don't use TypeScript, you'll benefit from these typings as they will help ensure we don't publish breaking changes unknowingly and if you use VSCode you'll benefit from these typings with the built-in Intellisense!

Support for Flow!

Another awesome contribution by @stereobooster. We're now generating flow type definitions from the TypeScript definitions, so if you're on the Flow train, you'll get more type-safety when working with downshift!

We're on spectrum!

downshift

Yeehaw! Join us there to talk about the present and future of downshift and get help/help others.

Thanks

This release and these amazing features would not be possible without help from all our open source contributors. I'd like to especially thank these awesome people:

@stereobooster, @franklixuefei, @dovidweisz, @Antontelesh, @tansongyang, @Andarist, @cycomachead, @mperrotti, @SiTaggart, and @1Copenut

Thank you!

See the release notes for more info on this release