“Modelo Redux Create React App” Respostas de código

Modelo Redux Create React App

npx create-react-app my-app --template redux
Gorgeous Goshawk

Modelo de loja Redux

import { createStore , applyMiddleware , compose } from "redux";
import rootReducer from './reducers/rootReducer.js'
import thunk from 'redux-thunk'
import { Provider } from "react-redux";

const store = createStore(
  rootReducer,
  compose(
    applyMiddleware(thunk),
    window.__REDUX_DEVTOOLS_EXTENSION__ && window.__REDUX_DEVTOOLS_EXTENSION__()
  )
);
ReactDOM.render( 
  <Provider store = {store}>
    <App /> </Provider>,
  document.getElementById("root")
);
Faryad Az Zim

Respostas semelhantes a “Modelo Redux Create React App”

Perguntas semelhantes a “Modelo Redux Create React App”

Mais respostas relacionadas para “Modelo Redux Create React App” em JavaScript

Procure respostas de código populares por idioma

Procurar outros idiomas de código