Questions tagged [react-alt]

A Flux-compliant library in Javascript

Homepage: http://alt.js.org/

Code: https://github.com/goatslacker/alt

Chat: https://reactiflux.slack.com/messages/alt/

Flux is a way of thinking about data flow in your javascript applications. Alt is an implementation that provides Actions and Stores.

14 questions
15
votes
4 answers

React.js Decorators are not supported yet in 6.x pending proposal update

The technologies that i am using to build my app is React, Web-pack, Babel and AlT(flux implementation) I'm getting an error when web pack tries to compile my app. Not sure what libraries i am missing. Could someone please advice ? ##.babelrc…
Erkan Demir
  • 785
  • 1
  • 8
  • 24
3
votes
3 answers

Invariant Violation: Dispatch.dispatch(...): Cannot dispatch in the middle of a dispatch

I am using ALT for my ReactJS project. I am getting the cannot 'dispatch' error if the ajax call is not yet done and I switch to another page. Mostly, this is how my project is setup. I have action, store and component. I querying on the server on…
RodM
  • 426
  • 1
  • 5
  • 19
1
vote
1 answer

Programmatically adding handlers to react form handler

In trying to cut down on boilerplate code I'm trying to add handlers for common form fields to the handler object that will highlight the bad field, show some error, etc. So far I have this: //FieldHelper.js exports.withStandardStoreHandlers =…
SVD
  • 4,743
  • 2
  • 26
  • 38
1
vote
1 answer

Open modal with ReactJS (es6) and siblings components

I have my app component with a Navbar component, and a ModalLogin component. App component: class App extends React.Component { render() { return (
{this.props.children} …
JVilla
  • 434
  • 4
  • 15
1
vote
1 answer

When a list of categories becomes available in store A, select one category and set its ID in store B

I have two stores - GroupsStore and ItemsFilterStore. The ItemsFilterStore's state should contain a choice of a single Group from the groups available in the GroupsStore, but: the groups are not initially available in the GroupsStore, so the choice…
Szczepan Hołyszewski
  • 2,707
  • 2
  • 25
  • 39
1
vote
0 answers

What's the right pattern to follow for an Altjs + ReactRouter project?

I started my first react app following this SurviveJS brilliant guide to develop a kanban app. This involves altjs as flux technology, really simple to use. The author suggests to use an AltContainer to link store(s) to the component(s), an easy…
Splact
  • 702
  • 2
  • 8
  • 15
1
vote
1 answer

obj is missing in props - alt

I am new to react. In my react+flux+alt+ES6 application I have three properties for search action. When I try to set default values I got errors. Action: import alt from 'altInstance'; import AttributeSectionWebAPIUtils from…
Anusha Nilapu
  • 1,243
  • 8
  • 24
  • 36
1
vote
2 answers

FindDOMNode flux/alt store

I'm trying to access a dom node from a store (using alt) in order to animate using velocity.js, however am only getting 'cannot read property of undefined'. Is it possible to use findDOMNode from an alt/flux store? import React from 'react' import…
Boyswan
  • 224
  • 1
  • 4
  • 12
1
vote
2 answers

What is the proper way to getInitialState with remote data in Reactjs?

IT IS SOLVED. The code was ok, the problem was with improper import. It is a long post (due to code samples). I'll appreciate your patience and will be very thankful for your help! We have a RoR back-end and React on the front-end and we are using…
Danny Ocean
  • 1,081
  • 2
  • 14
  • 30
1
vote
1 answer

React unlisten doesn't work on componentWillUnmount

I'm using alt with React 0.13.1. In my component below, unlisten doesn't work on componentWillUnmount. The component unmounts but I can see the polling still happening. Is there something I'm not understanding about how to unlisten? I don't have…
ben
  • 33
  • 1
  • 6
0
votes
2 answers

Why React component doesn't render?

I am making simple react app. I need to make an order. For that order I need a list of all users and products.I have CreateOrder component which has 2 variables in its state - users and products. Here is the constructor this.state.orders =…
Pavlin Petkov
  • 1,022
  • 3
  • 17
  • 38
0
votes
1 answer

React + Alt: Use data from multiple stores to make a request to DataSource

I am working on an app using React with Alt flux implementation. Currently, I'm trying to figure out the best way to use data from multiple Alt stores to compose a request to the backend. Say, I have a SheetDataStore, FiltersStore and a…
Gleb Kostyunin
  • 3,743
  • 2
  • 19
  • 36
0
votes
1 answer

React Action Callback do transition best practice

Case is that I add a new Item by click to my user over an action. When the Items is added the ActiveItemStore will be updated and I want then navigate to the active Item. But currently the transition is called before the Store is updated. Current…
Alexander Schranz
  • 2,154
  • 2
  • 25
  • 42
0
votes
1 answer

Flux(Alt): ReferenceError: localStorage is not defined

I'm trying to store session data to the localStorage but I receive an error. "ReferenceError: localStorage is not defined" Here is the code. import alt from '../alt'; import UserActions from '../actions/UserActions.js'; // To Do: Inplement…
Atsuhiro Teshima
  • 1,508
  • 1
  • 12
  • 21