Giter VIP home page Giter VIP logo

feedbacks's People

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

feedbacks's Issues

Please, write if you use this library (if you don't, you could also explain "why not"). Feedback needed.

I put link to this library on few places.

But this turned out to be not popular library (only 3 Github stars, zero issues from users).

I wonder if somebody uses it. If you do, feel free to tell me about "in what applications you use Feedbacks, how is your experience using Feedbacks, what features would you like to see in future versions etc."

If you don't use it. Why not? Is Readme not clear of "what Feedbacks are for?". Or are you reluctant to use not-popular library? Or maybe current popular solutions for Redux (Redux Thunk, Redux Saga, Redux-Observable etc.) are sufficient? Or from other reasons?

Well, not sure if this is written in clear way in README but main purposes of Feedbacks are:

1. to make work in Redux pleasant and concise so it solves a problem: there's too much boilerplate in Redux apps.
2. to handle side effects in more direct way (without needless boilerplate) so it solves a problem of "logic is dispersed over the project and I don't see what's going on. and to make one thing, I have to create 5 different helper actions, reducers, sagas, whatever". In Feedbacks generally you will need **less** actions and less reducers because you can effectively set a value asynchronously(!). Look into `fx.next` for example
3. to enable division of state into small pieces, to enable scalability idea is that writing Redux apps should not be an operating on one big state tree, because it's not scalable, but that you should divide your state into small pieces (similar idea to `combineReducers` from Redux)

Do you also think that problems above are worth solving? Or you don't really see them as a problem? Or maybe do you have other solution for them?

Things to do

  • dispatching effects

  • array support

  • services

  • auto-(de)normalized store (with use of Transmutable library)

  • collection helpers (addItem, setItem etc.) should they be effects?

  • naming, api design
    questions to ask:

    • flow / story?
  • add some additional effects (maybe we won't need all of it, just examples).

    • fx.random
    • fx.ask, fx.alert, fx.confirm, fx.log
    • fx.id, fx.genId, fx.createId or something
    • fx.time, fx.now, fx.date? (maybe not all of these. Just examples of naming)
    • fx.many
    • fx.error
    • fx.cancel
    • fx.sendBack instead of yield for communicating in spawned actions
  • consider using generators as some kind of saga-like effect

  • polish the calendar example

    • adding / removing / updating notes
    • styling
    • drag'n'drop
  • revamp README, make it more clean.

    • readme should show how to fetch resources with more idiomatic way using fx.effect (or other fx methods), not by just returning a function wrapped promise
  • documentation on Github pages with few interactive examples

  • integration with Redux dev tools

  • remove plain functions from effects if they are finished #3

TypeError: eff.cancel is not a function (when assigning function effect twice)

steps to reproduce:

        const store = createStore({
            a: init(0).on('foo', () => () => 1)
        }, createFeedbacks());
        store.dispatch({type: 'foo'});
        store.dispatch({type: 'foo'});
 TypeError: eff.cancel is not a function
  at visitNode (src/resmix.js:350:37)
  at visitNode (src/resmix.js:367:29)
  at Object.action [as dispatch] (src/resmix.js:371:17)

How it should work and why this bug occurs:

Feedbacks is designed to auto-cancel previous effect on same property.
e.g. () => new Observable(...) cancel previous observable bound to property.

But effects can be various things (including functions) and when a function is returned, Feedbacks somewhat wants to cancel previous function by calling result.cancel() when result is a result of running effect in EffectRunner. But EffectRunner doesn't always return cancellable result.

So either it should cancel previous function or just checking if eff.cancel exists in result.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.