
Research
/Security News
Miasma Mini Shai-Hulud Hits ImmobiliareLabs npm Packages
Miasma Mini Shai-Hulud hits @immobiliarelabs Backstage plugins, targeting GitLab and LDAP auth packages on npm.
@kuindji/react-observable
Advanced tools
React hooks for Observable (@kuindji/observable)
import Observable from "@kuindji/observable"
import { useOn } from "@kuindji/observable-react"
function MyComponent() {
// create it here or get from somewhere else
const observable = useMemo(() => new Observable(), []);
// all parameters are dynamic
useOn(observable, "eventName", callbackFunction, options = {});
useOn(observable, {
eventName1: callbackFunction1,
eventName2: callbackFunction2
});
useOn(observable, [
{ name: "eventName1", listener: callbackFunction1, options = {}},
{ name: "eventName2", listener: callbackFunction2, options = {}}
]);
return (
<></>
)
}
useObservable is a useContext wrapper and Provider is a predefined Context.
import Observable from "@kuindji/observable"
import { useOn, useObservable, Provider } from "@kuindji/observable-react"
function App() {
const observable = useMemo(() => new Observable(), []);
return (
<Provider observable={ observable }>
<MyComponent/>
</Provider>
)
}
function MyComponent() {
const observable = useObservable();
useOn(observable, ...);
return (...)
}
import { createContext } from "react"
import Observable from "@kuindji/observable"
import { useObservable, Provider } from "@kuindji/observable-react"
const ObservableContext = createContext();
function App() {
const observable = useMemo(() => new Observable(), []);
return (
<ObservableContext.Provider value={ observable }>
<MyComponent/>
</ObservableContext.Provider>
)
}
function MyComponent() {
const observable = useObservable(ObservableContext);
}
FAQs
React hooks for Observable (@kuindji/observable)
We found that @kuindji/react-observable demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Research
/Security News
Miasma Mini Shai-Hulud hits @immobiliarelabs Backstage plugins, targeting GitLab and LDAP auth packages on npm.

Security News
Rolldown paused Rust React Compiler integration after a 5MB binary size increase raised concerns about shipping React-specific code to all Vite users.

Security News
/Research
Mini Shai-Hulud expands into the Go ecosystem after hitting LeoPlatform npm packages and targeting GitHub Actions workflows.