Questions tagged [frp]

Functional reactive programming is programming paradigm for reactive programming

441 questions
15
votes
2 answers

Higher order FRP with React - why is it not happening?

Redux is a kind of first order FRP, like Elm used to be. It seems however that higher order FRP is not really being used together with react. Why is first order FRP useful with React and higher order not so useful ? Maybe higher-order-ism is not…
jhegedus
  • 18,516
  • 11
  • 84
  • 147
15
votes
1 answer

How to manage state without using Subject or imperative manipulation in a simple RxJS example?

I have been experimenting with RxJS for two weeks now, and although I love it in principle I just cannot seem to find and implement the correct pattern for managing state. All articles and questions appear to agree: Subject should be avoided where…
brokenalarms
  • 295
  • 3
  • 9
15
votes
2 answers

Is FRP a proper way to implement most "event-driven" things?

In my very first impression of Haskell, it's a language can handle "execute-then-result" things amazingly well. But I can't find how to implement "event-driven" things like games, or HTTP/FTP/TCPSocket servers. This question got answered after I…
snowmantw
  • 1,541
  • 1
  • 10
  • 24
14
votes
6 answers

How do I get the current time in Elm 0.17/0.18?

I had asked this question already: How do I get the current time in Elm? And answered it by writing my own (now deprecated) variant of start-app: http://package.elm-lang.org/packages/z5h/time-app/1.0.1 Of course the Elm architecture has since…
z5h
  • 21,947
  • 8
  • 64
  • 119
14
votes
1 answer

How to derive FRP from Directed Acyclic Graphs?

I am currently researching for my next project. This is in a pre-planning phase so this question is just to get an overview on existing technology. Setup I have a directed acyclic graph (DAG) with multiple inputs and output, think artificial…
fho
  • 6,578
  • 19
  • 63
13
votes
3 answers

How to best synchronize game engine and network server in Haskell?

I am designing a little soccer game where the game engine (that computes player moves etc.) runs on a server, and rendering and keyboard/mouse handling is done by the client. For the server (Haskell) I want to use Happstack for client-server…
martingw
  • 4,023
  • 2
  • 19
  • 26
13
votes
3 answers

Rxjs observing object updates and changes

I am currently trying to observe any changes to a given object including all of it's elements. The following code only fires when an object[x] is updates, but not if individually updating object[x]'s elements such as object[x][y]