How to use the redux-orm.createReducer function in redux-orm

To help you get started, we’ve selected a few redux-orm examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github GiraffeTools / GiraffeTools / app / porcupine / js / reducers / index.js View on Github external
import orm from "../models";
import auth from "../../../giraffe/js/reducers/auth";
import alerts from "../../../giraffe/js/reducers/alerts";
import modals from "./modals";
import ui from "./ui";
import user from "./user";
import scene from "./scene";

const config = {
  key: "porcupine",
  storage
};

const porcupineApp = persistCombineReducers(config, {
  orm: createReducer(orm), // database components
  scene,
  ui,
  alerts,
  modals,
  user,
  auth
});

export default porcupineApp;
github GiraffeTools / GiraffeTools / frontend / porcupine / reducers / index.js View on Github external
import auth from '../../giraffe/reducers/auth';
import alerts from '../../giraffe/reducers/alerts';
import modals from './modals';
import ui from './ui';
import grammars from './grammars';
import project from './project';
import projectConfig from './projectConfig';
import scene from './scene';

const config = {
  key: 'porcupine',
  storage,
};

const porcupineApp = persistCombineReducers(config, {
  orm: createReducer(orm), // database components
  scene,
  ui,
  alerts,
  grammars,
  modals,
  project,
  projectConfig,
  auth,
});

export default porcupineApp;
github SEL-Columbia / dokomoforms / dokomoforms / static / src / admin / js / create-survey / main.js View on Github external
'use strict';

import React from 'react';
import ReactDOM from 'react-dom';
import Application from './Application.babel.js';
import { Provider } from 'react-redux';
import { createStore, combineReducers } from 'redux';
import { createReducer } from 'redux-orm';
import bootstrap from './redux/bootstrap.babel.js';
import { orm } from './redux/models.babel.js';
import { currentSurveyIdReducer, defaultLanguageReducer } from './redux/reducers.babel.js';

const rootReducer = combineReducers({
	orm: createReducer(orm),
	currentSurveyId: currentSurveyIdReducer,
	default_language: defaultLanguageReducer
});

const store = createStore(rootReducer, bootstrap(orm));

ReactDOM.render(
  
    
  , document.getElementById('app'));
github carlesnunez / react-native-weather-app / src / reducers / root-reducer.js View on Github external
import navReducer from './navReducer';
import { FILL_CITY_AUTOCOMPLETE, OPEN_CITY_LIST,
    CLOSE_CITY_LIST, CHECK_CITY_WEATHER } from '../constants/ActionTypes';

export const root = (state = { cityList: [], selectCityInputOpened: false, selectedCity: '', weatherInfo: null }, action) => {
        switch (action.type) {
            case OPEN_CITY_LIST:
            return {cityList: [], selectCityInputOpened: true, weatherInfo: null };
            case CLOSE_CITY_LIST:
            return { cityList: [], selectCityInputOpened: false, selectedCity: '', weatherInfo: null };
            default:
            return state;
        }
    };

    const rootReducerCombined = combineReducers({ root, navReducer, orm: createReducer(orm) });

    export default rootReducerCombined;
github SEL-Columbia / dokomoforms / dokomoforms / static / src / admin / js / create-survey / main.babel.js View on Github external
'use strict';

import React from 'react';
import ReactDOM from 'react-dom';
import Application from './Application.babel.js';
import { Provider } from 'react-redux';
import { createStore, combineReducers } from 'redux';
import { createReducer } from 'redux-orm';
import bootstrap from './redux/bootstrap.babel.js';
import { orm } from './redux/models.babel.js';
import { currentSurveyIdReducer, submittedReducer } from './redux/reducers.babel.js';

 const rootReducer = combineReducers({
    orm: createReducer(orm),
    currentSurveyId: currentSurveyIdReducer,
    submitted: submittedReducer
 });

const store = createStore(rootReducer, bootstrap(orm));

ReactDOM.render(
  
    
  , document.getElementById('app'));
github gusbueno / awesome-notes / src / reducers / index.js View on Github external
import { combineReducers } from 'redux';
import { createReducer } from 'redux-orm';

import orm from '../orm';
import nav from './nav';
import notes from './notes';

const appReducer = combineReducers({
    nav,
    notes,
    orm: createReducer(orm)
});

export default appReducer;
github meltyshev / planka / client / src / reducers / orm.js View on Github external
import { createReducer } from 'redux-orm';

import orm from '../orm';

export default createReducer(orm);

redux-orm

Simple ORM to manage and query your state trees

MIT
Latest version published 4 years ago

Package Health Score

51 / 100
Full package analysis