{"maintainers":[{"name":"acdlite","email":"acdlite@me.com"},{"name":"jakxz","email":"jgkurian@me.com"}],"keywords":["flux","redux","actions","fsa"],"dist-tags":{"latest":"1.2.0"},"author":{"name":"Andrew Clark","email":"acdlite@me.com"},"description":"A human-friendly standard for Flux action objects","readme":"Flux Standard Action\n====================\n\n[![build status](https://img.shields.io/travis/acdlite/flux-standard-action/master.svg?style=flat-square)](https://travis-ci.org/acdlite/flux-standard-action)\n[![npm version](https://img.shields.io/npm/v/flux-standard-action.svg?style=flat-square)](https://www.npmjs.com/package/flux-standard-action)\n\n## Introduction\n\nA human-friendly standard for Flux action objects. Feedback welcome.\n\n### Motivation\n\nIt's much easier to work with Flux actions if we can make certain assumptions about their shape. For example, essentially all Flux actions have an identifier field, such as `type`, `actionType`, or `actionId`. Many Flux implementations also include a way for actions to indicate success or failure, especially as the result of a data-fetching operation. Defining a minimal, common standard for these patterns enables the creation of useful tools and abstractions.\n\n### Errors as a first class concept\n\nFlux actions can be thought of as an asynchronous sequence of values. It is important for asynchronous sequences to deal with errors. Currently, many Flux implementations don't do this, and instead define separate action types like `LOAD_SUCCESS` and `LOAD_FAILURE`. This is less than ideal, because it overloads two separate concerns: disambiguating actions of a certain type from the \"global\" action sequence, and indicating whether or not an action represents an error. FSA treats errors as a first class concept.\n\n### Design goals\n\n- **Human-friendly.** FSA actions should be easy to read and write by humans.\n- **Useful**. FSA actions should enable the creation of useful tools and abstractions.\n- **Simple.** FSA should be simple, straightforward, and flexible in its design.\n\n### Example\n\nA basic Flux Standard Action:\n\n```js\n{\n  type: 'ADD_TODO',\n  payload: {\n    text: 'Do something.'  \n  }\n}\n```\n\nAn FSA that represents an error, analogous to a rejected Promise:\n\n```js\n{\n  type: 'ADD_TODO',\n  payload: new Error(),\n  error: true\n}\n```\n\n## Actions\n\nAn action MUST\n\n- be a plain JavaScript object.\n- have a `type` property.\n\nAn action MAY\n\n- have an `error` property.\n- have a `payload` property.\n- have a `meta` property.\n\nAn action MUST NOT include properties other than `type`, `payload`, `error`, and `meta`.\n\n### `type`\n\nThe `type` of an action identifies to the consumer the nature of the action that has occurred. By convention, `type` is usually a string constant or a Symbol. If two types are the same, they MUST be strictly equivalent (using `===`).\n\n### `payload`\n\nThe optional `payload` property MAY be any type of value. It represents the payload of the action. Any information about the action that is not the `type` or status of the action should be part of the `payload` field.\n\nBy convention, if `error` is `true`, the `payload` SHOULD be an error object. This is akin to rejecting a promise with an error object.\n\n### `error`\n\nThe optional `error` property MAY be set to `true` if the action represents an error.\n\nAn action whose `error` is true is analogous to a rejected Promise. By convention, the `payload` SHOULD be an error object.\n\nIf `error` has any other value besides `true`, including `undefined` and `null`, the action MUST NOT be interpreted as an error.\n\n### `meta`\n\nThe optional `meta` property MAY be any type of value. It is intended for any extra information that is not part of the payload.\n\n## Utility functions\n\nThe module `flux-standard-action` is available on npm. It exports a few utility functions.\n\n```js\nimport { isFSA } from 'flux-standard-action';\n```\n### `isFSA(action)`\n\nReturns true if `action` is FSA compliant.\n\n## Libraries\n\n- [redux-actions](https://github.com/acdlite/redux-actions) - a set of helpers for creating and handling FSA actions in Redux.\n- [redux-promise](https://github.com/acdlite/redux-promise) - Redux promise middleware that supports FSA actions.\n- [redux-rx](https://github.com/acdlite/redux-rx) - RxJS utilities for Redux, including a middleware that supports FSA actions.\n","repository":{"type":"git","url":"git://github.com/acdlite/flux-standard-action.git"},"users":{"urbantumbleweed":true},"bugs":{"url":"https://github.com/acdlite/flux-standard-action/issues"},"license":"MIT","versions":{"0.1.0":{"name":"flux-standard-action","version":"0.1.0","description":"A human-friendly standard for Flux action objects","main":"lib/index.js","scripts":{"test":"make test","prepublish":"make clean build"},"keywords":["flux","redux","actions","fsa"],"author":{"name":"Andrew Clark","email":"acdlite@me.com"},"license":"MIT","devDependencies":{"babel":"^5.6.14","babel-core":"^5.6.15","babel-eslint":"^3.1.20","chai":"^3.0.0","eslint":"^0.24.0","eslint-config-airbnb":"0.0.6","mocha":"^2.2.5"},"dependencies":{"lodash.isplainobject":"^3.2.0"},"gitHead":"015e1c191ba3be48192fbf5a36177e8efe326113","_id":"flux-standard-action@0.1.0","_shasum":"ffb1f5d047a75922ce9443438d4e0f86ccd5e644","_from":".","_npmVersion":"2.12.0","_nodeVersion":"2.2.1","_npmUser":{"name":"opengov_dev","email":"services+npmjs-user@opengov.com"},"dist":{"shasum":"ffb1f5d047a75922ce9443438d4e0f86ccd5e644","tarball":"http://nexus.dui88.com:8081/nexus/content/repositories/npm-registry/flux-standard-action/-/flux-standard-action-0.1.0.tgz"},"maintainers":[{"name":"opengov_dev","email":"services+npmjs-user@opengov.com"}],"directories":{}},"0.2.0":{"name":"flux-standard-action","version":"0.2.0","description":"A human-friendly standard for Flux action objects","main":"lib/index.js","scripts":{"test":"make test","prepublish":"make clean build"},"keywords":["flux","redux","actions","fsa"],"author":{"name":"Andrew Clark","email":"acdlite@me.com"},"license":"MIT","devDependencies":{"babel":"^5.6.14","babel-core":"^5.6.15","babel-eslint":"^3.1.20","chai":"^3.0.0","eslint":"^0.24.0","eslint-config-airbnb":"0.0.6","mocha":"^2.2.5"},"dependencies":{"lodash.isplainobject":"^3.2.0"},"gitHead":"97582e267a5ee28f19459ce6f90a51381ae141c8","_id":"flux-standard-action@0.2.0","_shasum":"fd06d7ea564796f0a268c58f7076157ac15396df","_from":".","_npmVersion":"2.12.0","_nodeVersion":"2.2.1","_npmUser":{"name":"acdlite","email":"acdlite@me.com"},"dist":{"shasum":"fd06d7ea564796f0a268c58f7076157ac15396df","tarball":"http://nexus.dui88.com:8081/nexus/content/repositories/npm-registry/flux-standard-action/-/flux-standard-action-0.2.0.tgz"},"maintainers":[{"name":"acdlite","email":"acdlite@me.com"}],"directories":{}},"0.3.1":{"name":"flux-standard-action","version":"0.3.1","description":"A human-friendly standard for Flux action objects","main":"lib/index.js","scripts":{"test":"make test","prepublish":"make clean build"},"keywords":["flux","redux","actions","fsa"],"author":{"name":"Andrew Clark","email":"acdlite@me.com"},"license":"MIT","devDependencies":{"babel":"^5.6.14","babel-core":"^5.6.15","babel-eslint":"^3.1.20","chai":"^3.0.0","eslint":"^0.24.0","eslint-config-airbnb":"0.0.6","mocha":"^2.2.5"},"dependencies":{"lodash.isplainobject":"^3.2.0"},"gitHead":"6f9744fa3f998216a101860a3ba2f50ffebd05fa","_id":"flux-standard-action@0.3.1","_shasum":"923268d3d9e10724b5967b4597f8a071dbedeb47","_from":".","_npmVersion":"2.12.0","_nodeVersion":"2.2.1","_npmUser":{"name":"acdlite","email":"acdlite@me.com"},"dist":{"shasum":"923268d3d9e10724b5967b4597f8a071dbedeb47","tarball":"http://nexus.dui88.com:8081/nexus/content/repositories/npm-registry/flux-standard-action/-/flux-standard-action-0.3.1.tgz"},"maintainers":[{"name":"acdlite","email":"acdlite@me.com"}],"directories":{}},"0.4.0":{"name":"flux-standard-action","version":"0.4.0","description":"A human-friendly standard for Flux action objects","main":"lib/index.js","scripts":{"test":"make test","prepublish":"make clean build"},"keywords":["flux","redux","actions","fsa"],"author":{"name":"Andrew Clark","email":"acdlite@me.com"},"license":"MIT","devDependencies":{"babel":"^5.6.14","babel-core":"^5.6.15","babel-eslint":"^3.1.20","chai":"^3.0.0","eslint":"^0.24.0","eslint-config-airbnb":"0.0.6","mocha":"^2.2.5"},"dependencies":{"lodash.isplainobject":"^3.2.0"},"gitHead":"0fde0e8469c1177ef61a499408b5a65cd50b2452","_id":"flux-standard-action@0.4.0","_shasum":"8dfcb2f60a4c48d081bfad0f1eafe9c0e32083b7","_from":".","_npmVersion":"2.12.0","_nodeVersion":"2.2.1","_npmUser":{"name":"acdlite","email":"acdlite@me.com"},"dist":{"shasum":"8dfcb2f60a4c48d081bfad0f1eafe9c0e32083b7","tarball":"http://nexus.dui88.com:8081/nexus/content/repositories/npm-registry/flux-standard-action/-/flux-standard-action-0.4.0.tgz"},"maintainers":[{"name":"acdlite","email":"acdlite@me.com"}],"directories":{}},"0.5.0":{"name":"flux-standard-action","version":"0.5.0","description":"A human-friendly standard for Flux action objects","main":"lib/index.js","scripts":{"test":"make test","prepublish":"make clean build"},"keywords":["flux","redux","actions","fsa"],"author":{"name":"Andrew Clark","email":"acdlite@me.com"},"license":"MIT","devDependencies":{"babel":"^5.6.14","babel-core":"^5.6.15","babel-eslint":"^3.1.20","chai":"^3.0.0","eslint":"^0.24.0","eslint-config-airbnb":"0.0.6","mocha":"^2.2.5"},"dependencies":{"lodash.isplainobject":"^3.2.0"},"gitHead":"55896ff4c6ef1f1e15ccfc33c71c44603825fcd8","_id":"flux-standard-action@0.5.0","_shasum":"80028e807eabb10f89655c09334f753787a77c0d","_from":".","_npmVersion":"2.12.0","_nodeVersion":"2.2.1","_npmUser":{"name":"acdlite","email":"acdlite@me.com"},"dist":{"shasum":"80028e807eabb10f89655c09334f753787a77c0d","tarball":"http://nexus.dui88.com:8081/nexus/content/repositories/npm-registry/flux-standard-action/-/flux-standard-action-0.5.0.tgz"},"maintainers":[{"name":"acdlite","email":"acdlite@me.com"}],"directories":{}},"0.6.0":{"name":"flux-standard-action","version":"0.6.0","description":"A human-friendly standard for Flux action objects","main":"lib/index.js","scripts":{"test":"make test","prepublish":"make clean build"},"keywords":["flux","redux","actions","fsa"],"author":{"name":"Andrew Clark","email":"acdlite@me.com"},"license":"MIT","devDependencies":{"babel":"^5.6.14","babel-core":"^5.6.15","babel-eslint":"^3.1.20","chai":"^3.0.0","eslint":"^0.24.0","eslint-config-airbnb":"0.0.6","mocha":"^2.2.5"},"dependencies":{"lodash.isplainobject":"^3.2.0"},"gitHead":"dbc07ef5904df5614e6eab954a6d4b379608cfc9","_id":"flux-standard-action@0.6.0","_shasum":"e0ef9cdcc7442e9e76464d7b8d7a5c2a5012948d","_from":".","_npmVersion":"2.12.0","_nodeVersion":"2.2.1","_npmUser":{"name":"acdlite","email":"acdlite@me.com"},"dist":{"shasum":"e0ef9cdcc7442e9e76464d7b8d7a5c2a5012948d","tarball":"http://nexus.dui88.com:8081/nexus/content/repositories/npm-registry/flux-standard-action/-/flux-standard-action-0.6.0.tgz"},"maintainers":[{"name":"acdlite","email":"acdlite@me.com"}],"directories":{}},"0.6.1":{"name":"flux-standard-action","version":"0.6.1","description":"A human-friendly standard for Flux action objects","main":"lib/index.js","scripts":{"test":"make test","prepublish":"make clean build"},"keywords":["flux","redux","actions","fsa"],"author":{"name":"Andrew Clark","email":"acdlite@me.com"},"license":"MIT","devDependencies":{"babel":"^5.6.14","babel-core":"^5.6.15","babel-eslint":"^4.1.8","chai":"^3.0.0","eslint":"^0.24.0","eslint-config-airbnb":"0.0.6","mocha":"^2.2.5"},"dependencies":{"lodash.isplainobject":"^3.2.0"},"gitHead":"96349384bcf478fcba8c92a6e2a03798fa8a5a3b","_id":"flux-standard-action@0.6.1","_shasum":"6f34211b94834ea1c3cc30f4e7afad3d0fbf71a2","_from":".","_npmVersion":"3.3.6","_nodeVersion":"5.0.0","_npmUser":{"name":"acdlite","email":"acdlite@me.com"},"dist":{"shasum":"6f34211b94834ea1c3cc30f4e7afad3d0fbf71a2","tarball":"http://nexus.dui88.com:8081/nexus/content/repositories/npm-registry/flux-standard-action/-/flux-standard-action-0.6.1.tgz"},"maintainers":[{"name":"acdlite","email":"acdlite@me.com"}],"_npmOperationalInternal":{"host":"packages-5-east.internal.npmjs.com","tmp":"tmp/flux-standard-action-0.6.1.tgz_1454443066301_0.11490102671086788"},"directories":{}},"1.0.0":{"name":"flux-standard-action","version":"1.0.0","description":"A human-friendly standard for Flux action objects","main":"lib/index.js","files":["lib"],"scripts":{"prebuild":"npm run clean","build":"babel src --out-dir lib","clean":"rimraf lib/","lint":"eslint src/ test/","prepublish":"npm test && npm run build","pretest":"npm run lint","test":"cross-env NODE_ENV=test nyc mocha"},"repository":{"type":"git","url":"git://github.com/acdlite/flux-standard-action.git"},"keywords":["flux","redux","actions","fsa"],"author":{"name":"Andrew Clark","email":"acdlite@me.com"},"license":"MIT","devDependencies":{"babel-cli":"^6.16.0","babel-core":"^6.17.0","babel-eslint":"^7.0.0","babel-plugin-istanbul":"^2.0.1","babel-preset-es2015":"^6.16.0","babel-preset-stage-0":"^6.16.0","chai":"^3.0.0","coveralls":"^2.11.14","cross-env":"^3.1.1","eslint":"^3.7.1","eslint-config-airbnb-base":"^9.0.0","eslint-plugin-import":"^2.0.1","mocha":"^3.0.0","nyc":"^8.3.0","rimraf":"^2.5.4"},"dependencies":{"lodash.isplainobject":"^4.0.6","lodash.isstring":"^4.0.1","lodash.issymbol":"^4.0.1"},"nyc":{"all":true,"sourceMap":false,"instrument":false,"reporter":["text-summary","lcov"],"check-coverage":true,"lines":100,"statements":100,"functions":100,"branches":100},"gitHead":"1c8f1f8ce784604a505d459d398d1ceb32e547f9","bugs":{"url":"https://github.com/acdlite/flux-standard-action/issues"},"homepage":"https://github.com/acdlite/flux-standard-action#readme","_id":"flux-standard-action@1.0.0","_shasum":"24b84b627386714e33a0f07773931fc4b5fc452e","_from":".","_npmVersion":"3.10.8","_nodeVersion":"7.0.0","_npmUser":{"name":"jakxz","email":"jgkurian@me.com"},"dist":{"shasum":"24b84b627386714e33a0f07773931fc4b5fc452e","tarball":"http://nexus.dui88.com:8081/nexus/content/repositories/npm-registry/flux-standard-action/-/flux-standard-action-1.0.0.tgz"},"maintainers":[{"name":"acdlite","email":"acdlite@me.com"},{"name":"jakxz","email":"jgkurian@me.com"}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/flux-standard-action-1.0.0.tgz_1477583348495_0.7645706189796329"},"directories":{}},"1.1.0":{"name":"flux-standard-action","version":"1.1.0","description":"A human-friendly standard for Flux action objects","main":"lib/index.js","typings":"lib/index.d.ts","files":["lib"],"scripts":{"prebuild":"npm run clean","build":"babel src --out-dir lib --copy-files","clean":"rimraf lib/","lint":"eslint src/ test/","prepublish":"npm test && npm run build","pretest":"npm run lint","test":"cross-env NODE_ENV=test nyc mocha","posttest":"tsc"},"repository":{"type":"git","url":"git://github.com/acdlite/flux-standard-action.git"},"keywords":["flux","redux","actions","fsa"],"author":{"name":"Andrew Clark","email":"acdlite@me.com"},"license":"MIT","devDependencies":{"babel-cli":"^6.18.0","babel-core":"^6.18.2","babel-eslint":"^7.1.1","babel-plugin-istanbul":"^3.0.0","babel-preset-es2015":"^6.18.0","babel-preset-stage-0":"^6.16.0","chai":"^3.5.0","conventional-github-releaser":"^1.1.3","coveralls":"^2.11.15","cross-env":"^3.1.3","dotenv":"^4.0.0","eslint":"^3.10.2","eslint-config-airbnb-base":"^11.0.1","eslint-plugin-import":"^2.2.0","eslint-plugin-typescript":"^0.1.0","mocha":"^3.1.2","nyc":"^10.0.0","rimraf":"^2.5.4","typescript":"^2.0.10","typescript-eslint-parser":"^1.0.2"},"dependencies":{"lodash.isplainobject":"^4.0.6","lodash.isstring":"^4.0.1","lodash.issymbol":"^4.0.1"},"nyc":{"all":true,"sourceMap":false,"instrument":false,"reporter":["text-summary","lcov"],"check-coverage":true,"lines":100,"statements":100,"functions":100,"branches":100},"gitHead":"db58c2ea813242db5cf890e9c03a8526a13e93d9","bugs":{"url":"https://github.com/acdlite/flux-standard-action/issues"},"homepage":"https://github.com/acdlite/flux-standard-action#readme","_id":"flux-standard-action@1.1.0","_shasum":"114a014e70c8830505129511e043880f0961fb38","_from":".","_npmVersion":"4.0.5","_nodeVersion":"7.4.0","_npmUser":{"name":"jakxz","email":"jgkurian@me.com"},"dist":{"shasum":"114a014e70c8830505129511e043880f0961fb38","tarball":"http://nexus.dui88.com:8081/nexus/content/repositories/npm-registry/flux-standard-action/-/flux-standard-action-1.1.0.tgz"},"maintainers":[{"name":"acdlite","email":"acdlite@me.com"},{"name":"jakxz","email":"jgkurian@me.com"}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/flux-standard-action-1.1.0.tgz_1485227158683_0.38568222569301724"},"directories":{}},"1.2.0":{"name":"flux-standard-action","version":"1.2.0","description":"A human-friendly standard for Flux action objects","main":"lib/index.js","typings":"lib/index.d.ts","files":["lib"],"scripts":{"prebuild":"npm run clean","build":"babel src --out-dir lib --copy-files","clean":"rimraf lib/","lint":"eslint src/ test/","prepublish":"npm test && npm run build","pretest":"npm run lint","test":"cross-env NODE_ENV=test nyc mocha","posttest":"tsc"},"repository":{"type":"git","url":"git://github.com/acdlite/flux-standard-action.git"},"keywords":["flux","redux","actions","fsa"],"author":{"name":"Andrew Clark","email":"acdlite@me.com"},"license":"MIT","devDependencies":{"babel-cli":"^6.18.0","babel-core":"^6.18.2","babel-eslint":"^7.1.1","babel-plugin-istanbul":"^4.0.0","babel-plugin-lodash":"^3.2.11","babel-preset-es2015":"^6.18.0","babel-preset-stage-0":"^6.16.0","chai":"^3.5.0","conventional-github-releaser":"^1.1.3","coveralls":"^2.11.15","cross-env":"^3.1.3","dirty-chai":"^1.2.2","dotenv":"^4.0.0","eslint":"^3.10.2","eslint-config-airbnb-base":"^11.0.1","eslint-plugin-import":"^2.2.0","eslint-plugin-typescript":"^0.1.0","mocha":"^3.1.2","nyc":"^10.0.0","rimraf":"^2.5.4","typescript":"^2.0.10","typescript-eslint-parser":"^2.0.0"},"dependencies":{"lodash":"^4.0.0"},"nyc":{"all":true,"sourceMap":false,"instrument":false,"reporter":["text-summary","lcov"],"check-coverage":true,"lines":100,"statements":100,"functions":100,"branches":100},"gitHead":"74f54c87d4829da47bdc19299e787c7359ae8d15","bugs":{"url":"https://github.com/acdlite/flux-standard-action/issues"},"homepage":"https://github.com/acdlite/flux-standard-action#readme","_id":"flux-standard-action@1.2.0","_shasum":"d2d41612dde4cebddd11a76cfead8e84fc69ebdc","_from":".","_npmVersion":"4.1.2","_nodeVersion":"7.6.0","_npmUser":{"name":"jakxz","email":"jgkurian@me.com"},"dist":{"shasum":"d2d41612dde4cebddd11a76cfead8e84fc69ebdc","tarball":"http://nexus.dui88.com:8081/nexus/content/repositories/npm-registry/flux-standard-action/-/flux-standard-action-1.2.0.tgz"},"maintainers":[{"name":"acdlite","email":"acdlite@me.com"},{"name":"jakxz","email":"jgkurian@me.com"}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/flux-standard-action-1.2.0.tgz_1487960247324_0.6643469105474651"},"directories":{}}},"name":"flux-standard-action","time":{"modified":"2017-02-24T18:17:27.586Z","created":"2015-07-02T01:56:03.886Z","0.1.0":"2015-07-02T01:56:03.886Z","0.2.0":"2015-07-02T05:49:15.291Z","0.3.1":"2015-07-02T06:11:48.421Z","0.4.0":"2015-07-02T19:35:50.591Z","0.5.0":"2015-07-03T06:13:47.708Z","0.6.0":"2015-07-03T18:31:39.460Z","0.6.1":"2016-02-02T19:57:48.421Z","1.0.0":"2016-10-27T15:49:10.503Z","1.1.0":"2017-01-24T03:05:58.923Z","1.2.0":"2017-02-24T18:17:27.586Z"},"readmeFilename":"README.md","homepage":"https://github.com/acdlite/flux-standard-action#readme"}