
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.
rxjs-hooks-taro
Advanced tools
本库 fork 自 rxjs-hooks 具体使用细节,请翻看 rxjs-hooks
Using npm:
$ npm i --save rxjs-hooks-taro
Or yarn:
$ yarn add rxjs-hooks-taro
import Taro, { useState } from '@tarojs/taro'
import { View, Text, Button } from '@tarojs/components'
import { useObservable } from 'rxjs-hooks-taro'
import './index.less'
import { Subject, interval } from 'rxjs';
import { tap, map, withLatestFrom } from 'rxjs/operators';
interface IProps {}
function Index (props: IProps) {
const [count$] = useState(new Subject<number>());
const count = useObservable(() => {
return count$.pipe(
tap(count => console.log('count ==>', count)),
withLatestFrom(interval(1000)),
map(([count, timeCount]) => count + timeCount)
)
}
, 0);
return (
<View className='index'>
<Text>count: {count}</Text>
<Button onClick={() => {
count$.next(count + 1)
}}> + 1</Button>
<Button> - 1</Button>
</View>
)
}
export default Index;
FAQs
Taro hooks for RxJS
We found that rxjs-hooks-taro 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.