New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

microcosm

Package Overview
Dependencies
Maintainers
1
Versions
233
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

microcosm - npm Package Versions

1
24

9.6.0

Diff

Changelog

Source

9.6.0

Noticeable changes

  • The deserialize lifecycle method is now provided the entire raw state as the action parameters. This means that it is now available as the second argument in store callbacks.
  • Similarly, the serialize lifecycle method is now provided the entire app state in the action. This means that it is now available as the second argument in store callbacks.

Internal changes

  • Tweaks to lazy callback executed after app.push for better optimization
  • Tweaks to flatten for better optimization
  • Renamed async utility to coroutine
  • Reworked transactions to expose future lifecycle methods
  • Retain 100% test coverage

Upgrading

There are no breaking changes for this release.

nhunzaker
published 9.6.0-edge •

nhunzaker
published 9.5.0 •

Changelog

Source

9.5.0

  • Upgrade dependencies
  • Use fixed versions for dependencies
nhunzaker
published 9.4.1 •

Changelog

Source

9.4.1

Internal changes

  • Fixed bug where lifecycle methods used as registered actions did not properly stringify.
nhunzaker
published 9.4.0 •

Changelog

Source

9.4.0

Noticeable changes

  • Exposed lifecycle actions under microcosm/lifecycle. See the upgrading section for more notes.

Internal changes

  • getInitialState, serialize, and deserialize are now triggered by actions. We call them lifecycle actions. Their associated counterparts are willStart, willSerialize, and willDeserialize. There is no obligation to use these lifecycle actions, the store methods should work all the same.

Upgrading

This version adds lifecycle actions. This does not make any breaking change to the Microcosm API, however it provides us better internal consistency.

These lifecycle actions are still undergoing development (names may change, etc, but we'll keep you posted). However if you would like to give them a spin, consider the following code example:

import { willStart } from 'microcosm/lifecycle'
import { addPlanet } from 'actions/planets'

const Planets = {
  reset() {
    return []
  },
  add(records, item) {
    return records.concat(item)
  },
  register() {
    return {
      [willStart]: Planets.reset,
      [addPlanet]: Planets.add
    }
  }
}
nhunzaker
published 9.3.0 •

Changelog

Source

9.3.0

Noticeable changes

  • Store registration methods can return non-function values. When this is the case, it will use this value as the new state.
nhunzaker
published 9.2.0 •

Changelog

Source

9.2.0

Noticeable changes

  • Plugins will now validate that their register property is a function. If this property is not present, it will skip this validation and continue to the next plugin.

Internal changes

  • Internalized is-generator package to reduce dependencies and cut some dead code.
  • Refactored the install process to prevent needless extension and simplify the installation queue.

Upgrading

All changes are purely internal polish. There should be no additional required action. The build is about 100 bytes smaller, but who's counting? :)

nhunzaker
published 9.2.0-alpha •

nhunzaker
published 9.1.0 •

Changelog

Source

9.1.0

Internal changes

  • Updates to the way transactions are created and rolled forward to improve efifciency and support dev tool development
nhunzaker
published 9.1.0-beta •

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc