動くコード図鑑技術記事現場の渡り方キャリア論すべての記事About
TypeScript

Store

出典: Typescript×ReduxでStateがundefinedに?確認すること!ソースコードを解説 / Store

Store (typescript)#3016f3544502
import {combineReducers,createStore,Action} from 'redux'
import CounterReducer, {IState} from "../Reducers/CounterReducer";
import {ActionType} from "../Actions/CounterAction";
 
const rootReducer = combineReducers(
	{CounterReducer}
	);
 
export default createStore(rootReducer);
 
export type ReduxState = {
	Counter : IState
};
 
export type ReduxAction = ActionType | Action;
▸ この snippet は実行結果未収録
▸ 実行結果は未収録です
  • id: #3016f3544502
  • lines: 15
  • extracted: 2026-06-10

Source収録記事

この snippet は記事の「ソースコードを解説 / Store」セクションに登場する。コードの前後の文脈・ハマりどころの解説は記事本文で。

同じ記事から

11
図鑑トップ