Menu
StateX LogoStateXDocs
GitHub
StateX LogoStateX
  • Docs
  • GitHub
  • Introduction
    • Getting Started
    • Core Concepts
    • Installation
  • Basic Tutorial
    • Intro
    • Atoms
    • Selectors
  • Examples
    • Form
    • Performance
    • Master Detail
    • TodoMVC
  • API Reference
    • StateXProvider
    • path
    • atom()
    • selector()
    • action()
    • useStateX()
    • useStateXValue()
    • useStateXValueSetter()
    • useStateXGetter()
    • useRemoveStateX()
    • useStateXCallback()
    • useStateXValueResolveable()
    • useStateXAction()
    • useStateXSnapshotCallback()
    • useStateXSnapshotSetter()

useStateXSnapshotSetter()

This hook returns a function that can be used to replace the state at a given path. This hook along with useStateXSnapshotCallback() can be used to implement Undo History.

function useStateXSnapshotSetter(): <T>(state: T, path: Path = []) => void
Edit this page
Previous
« useStateXSnapshotCallback()

Docs

  • Getting Started
  • GitHub

Community

  • LinkedIn
  • Twitter

More

  • CloudIO
  • Blog

Legal

  • Privacy
  • Cookies
Copyright © 2020 CloudIO, Inc.