Skip to content

Commit a2f767c

Browse files
committed
bump microsite version, update tuts
1 parent 042c820 commit a2f767c

File tree

3 files changed

+14
-17
lines changed

3 files changed

+14
-17
lines changed

build.sbt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
lazy val docs = (project in file("./docs"))
1+
lazy val docs = project
22
.enablePlugins(MicrositesPlugin)
33
.settings(
44
micrositeName := "xReact",

docs/src/main/tut/index.md

Lines changed: 12 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -19,21 +19,21 @@ npm install xreact --save
1919
yarn add xreact
2020
```
2121

22-
- Come from redux? :point_right: <https://xreact.oyanglul.us/Get-Started.html>
23-
- Come from fantasy land? :rainbow: <https://xreact.oyanglul.us/Fantasy.html>
24-
- Examples :point_down:
22+
- Come from redux? 👉 <https://xreact.oyanglul.us/Get-Started.html>
23+
- Come from fantasy land? 🌈 <https://xreact.oyanglul.us/Fantasy.html>
24+
- Examples 👇
2525
- <https://github.com/reactive-react/xreact/tree/master/examples>
2626
- <https://xreact.oyanglul.us/Examples.html>
2727

2828
## Features
2929

3030
### Purely Functional, Declarative, and Monadic
31-
In imperatively written code, you describe step-by-step how to process data. With `xreact`, we simply define data transformations, then compose them to form our data flow. There are no variables, no intermediate state, and no side effects in your data flow's data composition!
31+
In imperatively code, you have to describe verbose of how to process data. With `xreact`, we simply define data transformations, then compose them to form data flow. There are no variables, no intermediate state, and no side effects in your data flow's data composition!
3232

3333
### Typesafe and scalable
34-
xReact is 100% Typescript!, abstract Stream as Higher Kind type so easier to bring new FRP lib to integrete with xreact.
34+
xReact is 100% Typescript! Turn your runtime bugs into compile time errors, fail and fix early.
3535

36-
### Composable and Reusable `Plan`
36+
### High level but 0 cost abstraction
3737
In Redux, reducers' use of `switch` statements can make them difficult to compose. Unlike reducers, the function `x` return is simply a function which can easily compose.
3838

3939
```js
@@ -43,25 +43,22 @@ const plan1_x_plan2_x = compose(x(plan1), x(plan2))
4343
const Counter = plan1_x_plan2_x(CounterView)
4444
```
4545

46-
what really happen behind compose is actually ES6 style mixin, so there won't be any extra layer of HoC and no any performance overhead.
46+
What really happen behind compose is actually ES6 style mixin, so there won't be any extra layer of HoC and no any performance overhead.
4747

48-
### Easy to test, no need for mocks
49-
Because UI and UI behavior are loosely coupled, you can test a React component by just passing it data. Behaviors can be tested by calling actions and then verifying the state.
50-
51-
### Async actions made easy
48+
### Asynchronous made easy
5249
Asynchronous functions, such as Promises, can be converted to a stream and then flat-mapped.
5350

5451
```js
5552
intent$.filter(x=>x.kind=='rest')
56-
.flatMap(({url}) => Observable.fromPromise(fetch(url)))
53+
.flatMap(({url}) => fromPromise(fetch(url)))
5754
```
5855

59-
where `fetch(url)` will return a `Promise`,
56+
where `fetch(url)` will return a `Promise`, and fromPromise will transform a `Promise` into `Observable`, so you can flat it in intent stream which is also a `Observable`.
6057

6158
### Reactive libs of your choice
62-
xReact came with 2 FRP libs of choices, rxjs and mostjs, for any new lib you only need to implement the `StaticStream` with your prefered lib as Higher Kind Type.
59+
xReact came with 2 FRP libs of choices, rxjs and mostjs, for any new libs you only need to implement the `StaticStream` with your preferred lib as Higher Kind Type, just like how we done for [mostjs](https://github.com/reactive-react/xreact/blob/master/src/xs/most.ts).
6360

64-
more details about HKT implementation in TypeScript is [here](https://github.com/gcanti/fp-ts)
61+
More details about HKT implementation in TypeScript is [here](https://github.com/gcanti/fp-ts), but you don't really need to know this.
6562

6663
## Copyright and License
6764
All code is available to you under the MIT license. The design is informed by many other projects:

project/plugins.sbt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
addSbtPlugin("com.47deg" % "sbt-microsites" % "0.6.1")
1+
addSbtPlugin("com.47deg" % "sbt-microsites" % "0.6.3")

0 commit comments

Comments
 (0)