Bae Versions Save

react made easy

v1.4.0

6 years ago

reaqt has been renamed to bae for easier verbal conversations about it 😅

v1.3.0

7 years ago
  • Uses rapscallion under the hood
  • Render some content on the screen fast - don't keep your users waiting

Benchmarks:

ttfb (ms) total (ms)
without streaming 151 151
with streaming 22 110

v1.2.0

7 years ago



react made easy

   

asyncComponentWillMount

React has a lifecycle method that get's called on the server componentWillMount that can be used to set data for server rendering. But, it does not support asynchronous data fetching before rendering the component.

reaqt introduces a new lifecycle method to pages that runs only on the server.

import React from 'react'

export default class extends React.Component {
  constructor (props) {
    super(props)
    this.state = {username: 'siddharthkp'}
  }
  asyncComponentWillMount () {
    /* 
      Return a promise.
      It will get resolved on the server and passed as props to the component.
    */
    return axios.get(`https://api.github.com/users/${this.state.username}`)
  }
  render () {
    return <div>{this.props.bio}</div>
  }
}

v1.0.0

7 years ago



react made easy

   

  • Quick start ⚡️
  • Minimal tooling 🔧
  • Server rendered + out of the box optimisations 🚀
  • Dev mode with hot module replacement 📦