Skip to content

Conversation

@Luffi2539
Copy link
Collaborator

Initial Firebase setup with redux-saga-firebase library

@Luffi2539 Luffi2539 requested a review from edvardsk April 11, 2019 14:54
// Initialize Firebase
// Insert your credentials
export const config = {
apiKey: 'AIzaSyBPUuIONtxcQ3efdGpMGbJVEn6fUG_1E5g',
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

move to env
apiKey: process.env.FIREBASE_API_KEY


export function* addFirebaseDataSaga({ payload }) {
if (payload.name && payload.age) {
yield call(rsf.firestore.addDocument, 'user', payload);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

each action should dispatch start, end or error

export default (history) => combineReducers({
form: formReducer,

firebase: firebaseReducer,
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

check immutable

testSelector,
mapDispatchToProps,
),
firestoreConnect([
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

how to get firestore collection/element into selector/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants