Skip to content

Instantly share code, notes, and snippets.

@js2me
Last active May 21, 2019 12:33
Show Gist options
  • Select an option

  • Save js2me/269063b4aba78917d1f315d98d15f56b to your computer and use it in GitHub Desktop.

Select an option

Save js2me/269063b4aba78917d1f315d98d15f56b to your computer and use it in GitHub Desktop.
import { StonexModule } from 'stonex'
class UsersModule extends StonexModule {
state = []
addUser = user => this.setState([...this.state, user])
removeAllUsers = () => this.resetState()
}
export default UsersModule
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment