NOTE: this package is not compatible with Elm 0.19.1
Simulate ports for using the LocalStorage module from elm reactor.
LocalStorage
elm reactor
Your Msg, which wraps the key/value pair from a getItem return.
getItem
For real ports, you'll only care about the GetItem operation. You'll get Nothing for the Ports.
GetItem
Nothing
Ports
For simluated ports, you need to store the Ports in your Model.
Model
Create a Ports object from a message wrapper, usually just one of your Msg options.
Your Msg, which wraps the key/value pair from a
getItemreturn.For real ports, you'll only care about the
GetItemoperation. You'll getNothingfor thePorts.For simluated ports, you need to store the
Portsin yourModel.