99x / serverless-react-boilerplate

A serverless react boilerplate for offline development

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

The initial list of todos are not being persisted to the state

dinukadesilva opened this issue · comments

Actually, since init method does changes to the state, this init method has to be called in componentDidMount and init method has to be binded to the component too. Otherwise, the changes happen to the state are not being persisted.

https://github.com/99xt/serverless-react-boilerplate/blob/c55ea284b568aded687eda26591f6e02cf902ef4/web/src/components/app.js#L24