All Projects → evturn → Redux Connect Decorator

evturn / Redux Connect Decorator

React Redux's connect as a decorator.

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Redux Connect Decorator

Thinkful Workshop React Redux Node Mongodb Webpack2
Stars: ✭ 12 (-73.91%)
Mutual labels:  decorators, react-redux
Ember Arg Types
Runtime type checking & defaulting for glimmer component arguments powered by prop-types & decorators
Stars: ✭ 43 (-6.52%)
Mutual labels:  decorators
Fascia
Stars: ✭ 12 (-73.91%)
Mutual labels:  react-redux
Generator Jam3
This is a generator for Jam3 projects
Stars: ✭ 34 (-26.09%)
Mutual labels:  react-redux
Create React App Redux
React Router, Redux, Redux Thunk & Create React App boilerplate
Stars: ✭ 885 (+1823.91%)
Mutual labels:  react-redux
Hellobooks
A Single-Page Library Management App built with nodejs, express and react and redux
Stars: ✭ 37 (-19.57%)
Mutual labels:  react-redux
Mongoose Model Decorators
ES2016 decorator functions for building Mongoose models
Stars: ✭ 11 (-76.09%)
Mutual labels:  decorators
Decko
💨 The 3 most useful ES7 decorators: bind, debounce and memoize
Stars: ✭ 1,024 (+2126.09%)
Mutual labels:  decorators
React Apollo Decorators
Better decorators for Apollo and React
Stars: ✭ 39 (-15.22%)
Mutual labels:  decorators
Injection Js
Dependency injection library for JavaScript and TypeScript in 5.1K. It is an extraction of the Angular's ReflectiveInjector which means that it's well designed, feature complete, fast, reliable and well tested.
Stars: ✭ 962 (+1991.3%)
Mutual labels:  decorators
Emptyd Admin Webpack
基于typescript react webpack的脚手架
Stars: ✭ 30 (-34.78%)
Mutual labels:  react-redux
Reactspa
combination of react teconology stack
Stars: ✭ 911 (+1880.43%)
Mutual labels:  react-redux
Redux Micro Frontend
This is a library for using Redux to manage state for self-contained apps in a Micro-Frontend architecture. Each self-contained isolated app can have its own isolated and decoupled Redux store. The componentized stores interact with a global store for enabling cross-application communication.
Stars: ✭ 38 (-17.39%)
Mutual labels:  react-redux
Tvrboreact
Dream starter project: React, Redux, React Router, Webpack
Stars: ✭ 13 (-71.74%)
Mutual labels:  decorators
Typescript Hapi React Hot Loader Example
Simple TypeScript React Hot Loading example with Hapi Server-side rendering
Stars: ✭ 44 (-4.35%)
Mutual labels:  react-redux
React Retirement Calculator
A dynamically updating retirement calculator.
Stars: ✭ 29 (-36.96%)
Mutual labels:  react-redux
Taliesin
Lightweight audio streaming server
Stars: ✭ 35 (-23.91%)
Mutual labels:  react-redux
React Antd Admin Template
一个基于React+Antd的后台管理模版,在线预览https://nlrx-wjc.github.io/react-antd-admin-template/
Stars: ✭ 1,022 (+2121.74%)
Mutual labels:  react-redux
Hapi React Hot Loader Example
Simple React Hot Loading example with Hapi Server-side rendering
Stars: ✭ 44 (-4.35%)
Mutual labels:  react-redux
Ts2redux
Compile standard TypeScript classes to Redux or React Context API
Stars: ✭ 39 (-15.22%)
Mutual labels:  react-redux
                          ______                                   __ 
                         / ____ \_________  ____  ____  ___  _____/ /_
                        / / __ `/ ___/ __ \/ __ \/ __ \/ _ \/ ___/ __/
                       / / /_/ / /__/ /_/ / / / / / / /  __/ /__/ /_  
                       \ \__,_/\___/\____/_/ /_/_/ /_/\___/\___/\__/  
                        \____/                                        

Usage

import React, { Component } from 'react'
import connect from 'redux-connect-decorator'
import Footer from './components/Footer'
import Header from './components/Header'
import Messages from './components/Messages'
import { fetchInitialData, showSpinner } from './actions'

@connect(state => ({ 
  messages: state.messages,
  fetching: state.fetching,
}), { 
  fetchInitialData,
  showSpinner,
})

class App extends Component {
  componentDidMount() {
    this.props.fetchInitialData()
  }

  componentWillReceiveProps(nextProps) {
    if (nextProps.fetching) {
      this.props.showSpinner()
    }
  }

  render() {
    return (
      <div>
        <Header />
        <Messages items={this.props.messages} />
        <Footer />
      </div>
    )
  }
}

export default App

.babelrc

Listed in this order.

{
  "plugins": [
    "babel-plugin-transform-decorators-legacy",
    "babel-plugin-transform-decorators"
  ]
}
yarn
yarn add redux-connect-decorator
npm
npm install --save redux-connect-decorator
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].