Releases: async-library/react-async
React Async v7.0.3: Include README and LICENSE in bundle
This adds README.md
and LICENSE
to the packaged modules before publishing.
Specifically this fixes the project page on npmjs.com.
React Async v7.0.2: onCancel callback & SSR fix
This introduces the onCancel
callback and fixes server-side rendering.
DevTools v1.0.2
This adds README.md and LICENSE to the bundle before publishing.
DevTools v1.0.0
This is the first release for React Async DevTools. Current features include:
- Show all pending/fulfilled/rejected promises in all instances of React Async
- Slow down requests by adding a virtual latency
- Intercept new requests before they start, to manually continue later
React Async v7.0.0 is required to use the DevTools.
Usage example:
import DevTools from "react-async-devtools"
ReactDOM.render(
<>
<DevTools />
<App />
</>,
document.getElementById("root")
)
React Async v7.0.1: Fix invalid build artifact
v7 introduced a whole new project structure, which unfortunately resulted in a broken build artifact. This release fixes that.
React Async v7.0.0: DevTools support [deprecated]
This major release adds support for react-async-devtools
and comes with an entirely new project structure based on a monorepo. There are no breaking changes, but it's a major milestone for the project.
- Adds
debugLabel
prop which is used by DevTools to label promises/requests. - Uses
window.__REACT_ASYNC__. devToolsDispatcher
if it exists to pass events through the DevTools.
This version is deprecated because the build artifact was broken. This was fixed in v7.0.1.
DevTools v1.0.0-alpha.0 [deprecated]
First alpha release for React Async DevTools. Superceded by v1.0.0
v6.2.2: Fix TypeScript JSX element type
This updates the type definitions to use JSX.Element instead of React.ReactNode for AsyncChildren and helper component types.
v6.2.1: Fix TypeScript default export
Thanks to @aratcliffe for the PR.
This release should fix problems with TypeScript getting the wrong type for Async, as described in #54.
v6.2.0: Standalone helper components
This separates the <Async.Initial>
, <Async.Pending>
etc. helper components from <Async>
so they can be used with useAsync
as well.
import { useAsync, Pending } from "react-async"
function MyComponent() {
const state = useAsync(...)
return (
<Pending state={state}>
<p>This text is only rendered while performing the initial load.</p>
</Pending>
)
}