Package Exports
- common-codec-cli
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (common-codec-cli) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
CoCo, the Common Codec
Getting started
Download and install the CoCo CLI from npm.
npm install common-codec-cli
Use
CoCo is a command line interface that requires 3 inputs as arguments - action, codec, and input.
Action can be encode or decode Codec is one of jwt, base64, hex, uri, binary, or ascii Input is the string of text that you want to convert.
coco <action> <codec> <input> <option>Eg
coco encode base64 myclientid:myclientsecret
bXljbGllbnRpZDpteWNsaWVudHNlY3JldA==
coco decode jwt eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiYWRtaW4iOnRydWV9.TJVA95OrM7E2cBab30RMHrHDcEfxjoYZgeFONFh7HgQ
{
"sub": "1234567890",
"name": "John Doe",
"admin": true
}
coco decode hex 0011aa
4522
coco decode hex 0011aa rgb
0 17 170