Skip to content
This repository has been archived by the owner on Dec 13, 2023. It is now read-only.

updated example to correctly increment currenttime #212

Merged
merged 1 commit into from
May 29, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/guide/state-and-lifecycle.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ There's another form of `setState` we can use. When the new state we want our co
function MyComponent:didMount()
self:setState(function(state)
return {
currentTime = currentTime + state.currentTime
currentTime = 1 + state.currentTime
}
end)
end
Expand Down