Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

201
Views
React/redux notifications

I'm working on a react/redux project. I looking for a component or a package, that displays notification messages to the user, for example react-notify.

The components I've found (including react-notify) use refs:

<ReactNotify ref='notificator'/>

I want a package without refs, if one exists.

Thank you!

over 4 years ago · Santiago Trujillo
2 answers
Answer question

0

Look at redux-notifications. It's a pure redux solution without the use of refs. The documentation is a bit outdated, but this worked for me (the change is the actions).

You add the <Notifs /> component to the root of your project:

import { Provider }  from 'react-redux'
import { Notifs } from 'redux-notifications';

<Provider store={store}>
  <div>
    // ... other things like router ...
    <Notifs />
  </div>
</Provider>

Add the the notifReducer to your base reducer:

import { createStore, combineReducers } from 'redux'
import { reducer as notifReducer } from 'redux-notifications';
combineReducers({
  notifs: notifReducer,
  // ... more reducers here ...
})

And then use the built in actions to dispatch notifications:

import { actions } from 'redux-notifications';

action.notifSend({
    message: "I am a notification",
    kind,
    id: 1234,
    dismissAfter: 2000
})(dispatch)
over 4 years ago · Santiago Trujillo Report

0

I have recently developed a simple library to implement a react-redux notification system on your app and it doesn't need to use ref. Check it out react-redux-notifications. Any feedback would be appreciate it.

over 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!