Skip to content
This repository has been archived by the owner on Feb 2, 2021. It is now read-only.

Commit

Permalink
Update documentation (#40)
Browse files Browse the repository at this point in the history
  • Loading branch information
StijnRuts authored and paf31 committed Oct 5, 2018
1 parent f55fd95 commit 3e300f9
Show file tree
Hide file tree
Showing 12 changed files with 96 additions and 360 deletions.
9 changes: 0 additions & 9 deletions generated-docs/FRP.md

This file was deleted.

16 changes: 16 additions & 0 deletions generated-docs/FRP/Behavior.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,22 @@ sample_ :: forall event a b. IsEvent event => ABehavior event a -> event b -> ev

Sample a `Behavior` on some `Event`, discarding the event's values.

#### `gate`

``` purescript
gate :: forall event a. IsEvent event => ABehavior event Boolean -> event a -> event a
```

Filter an `Event` by the boolean value of a `Behavior`.

#### `gateBy`

``` purescript
gateBy :: forall event p a. IsEvent event => (p -> a -> Boolean) -> ABehavior event p -> event a -> event a
```

Sample a `Behavior` on some `Event` by providing a predicate function.

#### `unfold`

``` purescript
Expand Down
4 changes: 2 additions & 2 deletions generated-docs/FRP/Behavior/Keyboard.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@
#### `keys`

``` purescript
keys :: Behavior (Set Int)
keys :: Keyboard -> Behavior (Set String)
```

A `Behavior` which reports the keys which are currently pressed.

#### `key`

``` purescript
key :: Int -> Behavior Boolean
key :: Keyboard -> String -> Behavior Boolean
```

A `Behavior` which reports whether a specific key is currently pressed.
Expand Down
4 changes: 2 additions & 2 deletions generated-docs/FRP/Behavior/Mouse.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@
#### `position`

``` purescript
position :: Behavior (Maybe { x :: Int, y :: Int })
position :: Mouse -> Behavior (Maybe { x :: Int, y :: Int })
```

A `Behavior` which reports the current mouse position, if it is known.

#### `buttons`

``` purescript
buttons :: Behavior (Set Int)
buttons :: Mouse -> Behavior (Set Int)
```

A `Behavior` which reports the mouse buttons which are currently pressed.
Expand Down
6 changes: 3 additions & 3 deletions generated-docs/FRP/Behavior/Time.md
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
## Module FRP.Behavior.Time

#### `millisSinceEpoch`
#### `instant`

``` purescript
millisSinceEpoch :: Behavior Number
instant :: Behavior Instant
```

Get the current time in milliseconds since the epoch.

#### `seconds`

``` purescript
seconds :: Behavior Number
seconds :: Behavior Seconds
```

Get the current time in seconds since the epoch.
Expand Down
192 changes: 0 additions & 192 deletions generated-docs/FRP/Event.md

This file was deleted.

11 changes: 11 additions & 0 deletions generated-docs/FRP/Event/AnimationFrame.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
## Module FRP.Event.AnimationFrame

#### `animationFrame`

``` purescript
animationFrame :: Event Unit
```

Create an event which fires every frame (using `requestAnimationFrame`).


Loading

0 comments on commit 3e300f9

Please sign in to comment.