File: /home/imensosw/.npm/registry.npmjs.org/cssesc/.cache.json
{"_id":"cssesc","_rev":"8-b2ba168fb8ab26fb44d42f6ddada4db2","name":"cssesc","description":"A JavaScript library for escaping CSS strings and identifiers while generating the shortest possible ASCII-only output.","dist-tags":{"latest":"2.0.0"},"versions":{"0.1.0":{"name":"cssesc","version":"0.1.0","description":"A JavaScript library for escaping CSS strings and identifiers while generating the shortest possible ASCII-only output.","homepage":"http://mths.be/cssesc","main":"cssesc.js","bin":{"cssesc":"bin/cssesc"},"man":["man/cssesc.1"],"keywords":["css","escape","identifier","string","tool"],"licenses":[{"type":"MIT","url":"http://mths.be/mit"}],"author":{"name":"Mathias Bynens","url":"http://mathiasbynens.be/"},"repository":{"type":"git","url":"https://github.com/mathiasbynens/cssesc.git"},"bugs":{"url":"https://github.com/mathiasbynens/cssesc/issues"},"files":["LICENSE-MIT.txt","cssesc.js","bin/","man/"],"directories":{"test":"tests"},"scripts":{"test":"node tests/tests.js"},"dependencies":{},"devDependencies":{"grunt":"~0.4.1","grunt-shell":"~0.3.1","grunt-template":"~0.2.0","istanbul":"~0.1.42","qunit-clib":"~1.3.0","qunitjs":"~1.11.0","regenerate":"~0.5.2","requirejs":"~2.1.8"},"_id":"cssesc@0.1.0","dist":{"shasum":"c814903e45623371a0477b40109aaafbeeaddbb4","tarball":"https://registry.npmjs.org/cssesc/-/cssesc-0.1.0.tgz"},"_from":".","_npmVersion":"1.2.32","_npmUser":{"name":"mathias","email":"mathias@qiwi.be"},"maintainers":[{"name":"mathias","email":"mathias@qiwi.be"}]},"1.0.0":{"name":"cssesc","version":"1.0.0","description":"A JavaScript library for escaping CSS strings and identifiers while generating the shortest possible ASCII-only output.","homepage":"https://mths.be/cssesc","engines":{"node":">=4"},"main":"cssesc.js","bin":{"cssesc":"bin/cssesc"},"man":["man/cssesc.1"],"keywords":["css","escape","identifier","string","tool"],"license":"MIT","author":{"name":"Mathias Bynens","url":"https://mathiasbynens.be/"},"repository":{"type":"git","url":"git+https://github.com/mathiasbynens/cssesc.git"},"bugs":{"url":"https://github.com/mathiasbynens/cssesc/issues"},"files":["LICENSE-MIT.txt","cssesc.js","bin/","man/"],"scripts":{"build":"grunt template","test":"mocha tests","cover":"istanbul cover --report html node_modules/.bin/_mocha tests -- -u exports -R spec"},"devDependencies":{"codecov":"^1.0.1","grunt":"^1.0.1","grunt-template":"^1.0.0","istanbul":"^0.4.4","mocha":"^2.5.3","regenerate":"^1.2.1","requirejs":"^2.1.16"},"gitHead":"3c3cbe285bbea1961e33d739ccc17ec4dcd66479","_id":"cssesc@1.0.0","_shasum":"5a6c0f71c93e99c4bda3dbd0f088e59f18676e56","_from":".","_npmVersion":"3.10.3","_nodeVersion":"6.4.0","_npmUser":{"name":"mathias","email":"mathias@qiwi.be"},"maintainers":[{"name":"mathias","email":"mathias@qiwi.be"}],"dist":{"shasum":"5a6c0f71c93e99c4bda3dbd0f088e59f18676e56","tarball":"https://registry.npmjs.org/cssesc/-/cssesc-1.0.0.tgz"},"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/cssesc-1.0.0.tgz_1475098788193_0.1862117713317275"},"directories":{}},"1.0.1":{"name":"cssesc","version":"1.0.1","description":"A JavaScript library for escaping CSS strings and identifiers while generating the shortest possible ASCII-only output.","homepage":"https://mths.be/cssesc","engines":{"node":">=4"},"main":"cssesc.js","bin":{"cssesc":"bin/cssesc"},"man":["man/cssesc.1"],"keywords":["css","escape","identifier","string","tool"],"license":"MIT","author":{"name":"Mathias Bynens","url":"https://mathiasbynens.be/"},"repository":{"type":"git","url":"git+https://github.com/mathiasbynens/cssesc.git"},"bugs":{"url":"https://github.com/mathiasbynens/cssesc/issues"},"files":["LICENSE-MIT.txt","cssesc.js","bin/","man/"],"scripts":{"build":"grunt template","test":"mocha tests","cover":"istanbul cover --report html node_modules/.bin/_mocha tests -- -u exports -R spec"},"devDependencies":{"codecov":"^1.0.1","grunt":"^1.0.1","grunt-template":"^1.0.0","istanbul":"^0.4.4","mocha":"^2.5.3","regenerate":"^1.2.1","requirejs":"^2.1.16"},"gitHead":"c124697ebb086fb3a20519a3d95141e62298f727","_id":"cssesc@1.0.1","_npmVersion":"5.6.0","_nodeVersion":"8.10.0","_npmUser":{"name":"mathias","email":"mathias@qiwi.be"},"dist":{"integrity":"sha512-S2hzrpWvE6G/rW7i7IxJfWBYn27QWfOIncUW++8Rbo1VB5zsJDSVPcnI+Q8z7rhxT6/yZeLOCja4cZnghJrNGA==","shasum":"ef7bd8d0229ed6a3a7051ff7771265fe7330e0a8","tarball":"https://registry.npmjs.org/cssesc/-/cssesc-1.0.1.tgz","fileCount":6,"unpackedSize":17663},"maintainers":[{"name":"mathias","email":"mathias@qiwi.be"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/cssesc_1.0.1_1521981680742_0.9027062666161223"}},"2.0.0":{"name":"cssesc","version":"2.0.0","description":"A JavaScript library for escaping CSS strings and identifiers while generating the shortest possible ASCII-only output.","homepage":"https://mths.be/cssesc","engines":{"node":">=4"},"main":"cssesc.js","bin":{"cssesc":"bin/cssesc"},"man":["man/cssesc.1"],"keywords":["css","escape","identifier","string","tool"],"license":"MIT","author":{"name":"Mathias Bynens","url":"https://mathiasbynens.be/"},"repository":{"type":"git","url":"git+https://github.com/mathiasbynens/cssesc.git"},"bugs":{"url":"https://github.com/mathiasbynens/cssesc/issues"},"files":["LICENSE-MIT.txt","cssesc.js","bin/","man/"],"scripts":{"build":"grunt template && babel cssesc.js -o cssesc.js","test":"mocha tests","cover":"istanbul cover --report html node_modules/.bin/_mocha tests -- -u exports -R spec"},"devDependencies":{"babel-cli":"^6.26.0","babel-preset-env":"^1.6.1","codecov":"^1.0.1","grunt":"^1.0.1","grunt-template":"^1.0.0","istanbul":"^0.4.4","mocha":"^2.5.3","regenerate":"^1.2.1","requirejs":"^2.1.16"},"gitHead":"12a4aeca706d4fc589fd645fa9b27f83414a46df","_id":"cssesc@2.0.0","_npmVersion":"5.8.0","_nodeVersion":"8.10.0","_npmUser":{"name":"mathias","email":"mathias@qiwi.be"},"dist":{"integrity":"sha512-MsCAG1z9lPdoO/IUMLSBWBSVxVtJ1395VGIQ+Fc2gNdkQ1hNDnQdw3YhA71WJCBW1vdwA0cAnk/DnW6bqoEUYg==","shasum":"3b13bd1bb1cb36e1bcb5a4dcd27f54c5dcb35703","tarball":"https://registry.npmjs.org/cssesc/-/cssesc-2.0.0.tgz","fileCount":6,"unpackedSize":17831,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJa4DseCRA9TVsSAnZWagAAO04P/0Eq1qLMHXgPqvhZXJcU\naCq8AflzpZdmgtSE7tV9XdjUhW5uSyM7XFBCl0J9E6VrC9mUzblQz15/c1b2\n6mNxBfob+nI83SK8dL1HLU/NxAnPXAqtbfHYHCX4dwYV1XNxWlFPz/CY7DBG\nUbS7h05QN+tMTUY6iTZJd5v+bTNUHcJ6IBUc/iMG9K8vnll97vfvC2KK95KN\n9eSIL5NLxolAqS01uA7rdByvW2eEdemDy21SAu0Ag/jm2AjO8Uc5aAg1ckvN\n3J0/OpLDGRsiwKiiP312bOmvgOQpFSMafRSCcChaECG2ponjnP80ZfRrMDMt\n0UUAGAJKHKeNMlvJyLGju9MbgRR/Zbso0/bFgXeJ4Qca2G0tWU3DauGc6mbW\n1lGoXx4qnZdwF7mm4UHqdtfy0smmrNuT+X6f+V11Nq6lDw92PiBaNoarBlwd\nfSkeewCu9e7rUJSOny4xUbJ1OcA5CB0fbwvf1S30Rgs9aJIiEU2mQCcNCLUh\nMFGWuc1I2PiMvaQgs+/rdruYzHk4oFNQ8ISkYmFcEFcWqKDjOWque/Rtn4Uv\n7P0avA8BaM9dnDS4BJjI/z+0vZGrmgqdyc5Nu9gWPWfg0bwIgrx1hozEOIuT\nT7jS838uIMuJUlQ78QkzfDbRnuCr3Nk2jMMtwJZyDotW/e59IkNqDSu/KDvD\nqGfp\r\n=lPoq\r\n-----END PGP SIGNATURE-----\r\n"},"maintainers":[{"name":"mathias","email":"mathias@qiwi.be"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/cssesc_2.0.0_1524644637233_0.5067917713067536"}}},"readme":"# cssesc [](https://travis-ci.org/mathiasbynens/cssesc) [](https://codecov.io/gh/mathiasbynens/cssesc)\n\nA JavaScript library for escaping CSS strings and identifiers while generating the shortest possible ASCII-only output.\n\nThis is a JavaScript library for [escaping text for use in CSS strings or identifiers](https://mathiasbynens.be/notes/css-escapes) while generating the shortest possible valid ASCII-only output. [Here’s an online demo.](https://mothereff.in/css-escapes)\n\n[A polyfill for the CSSOM `CSS.escape()` method is available in a separate repository.](https://mths.be/cssescape) (In comparison, _cssesc_ is much more powerful.)\n\nFeel free to fork if you see possible improvements!\n\n## Installation\n\nVia [npm](https://www.npmjs.com/):\n\n```bash\nnpm install cssesc\n```\n\nIn a browser:\n\n```html\n<script src=\"cssesc.js\"></script>\n```\n\nIn [Node.js](https://nodejs.org/):\n\n```js\nconst cssesc = require('cssesc');\n```\n\nIn Ruby using [the `ruby-cssesc` wrapper gem](https://github.com/borodean/ruby-cssesc):\n\n```bash\ngem install ruby-cssesc\n```\n\n```ruby\nrequire 'ruby-cssesc'\nCSSEsc.escape('I ♥ Ruby', is_identifier: true)\n```\n\nIn Sass using [`sassy-escape`](https://github.com/borodean/sassy-escape):\n\n```bash\ngem install sassy-escape\n```\n\n```scss\nbody {\n content: escape('I ♥ Sass', $is-identifier: true);\n}\n```\n\n## API\n\n### `cssesc(value, options)`\n\nThis function takes a value and returns an escaped version of the value where any characters that are not printable ASCII symbols are escaped using the shortest possible (but valid) [escape sequences for use in CSS strings or identifiers](https://mathiasbynens.be/notes/css-escapes).\n\n```js\ncssesc('Ich ♥ Bücher');\n// → 'Ich \\\\2665 B\\\\FC cher'\n\ncssesc('foo 𝌆 bar');\n// → 'foo \\\\1D306 bar'\n```\n\nBy default, `cssesc` returns a string that can be used as part of a CSS string. If the target is a CSS identifier rather than a CSS string, use the `isIdentifier: true` setting (see below).\n\nThe optional `options` argument accepts an object with the following options:\n\n#### `isIdentifier`\n\nThe default value for the `isIdentifier` option is `false`. This means that the input text will be escaped for use in a CSS string literal. If you want to use the result as a CSS identifier instead (in a selector, for example), set this option to `true`.\n\n```js\ncssesc('123a2b');\n// → '123a2b'\n\ncssesc('123a2b', {\n 'isIdentifier': true\n});\n// → '\\\\31 23a2b'\n```\n\n#### `quotes`\n\nThe default value for the `quotes` option is `'single'`. This means that any occurences of `'` in the input text will be escaped as `\\'`, so that the output can be used in a CSS string literal wrapped in single quotes.\n\n```js\ncssesc('Lorem ipsum \"dolor\" sit \\'amet\\' etc.');\n// → 'Lorem ipsum \"dolor\" sit \\\\\\'amet\\\\\\' etc.'\n// → \"Lorem ipsum \\\"dolor\\\" sit \\\\'amet\\\\' etc.\"\n\ncssesc('Lorem ipsum \"dolor\" sit \\'amet\\' etc.', {\n 'quotes': 'single'\n});\n// → 'Lorem ipsum \"dolor\" sit \\\\\\'amet\\\\\\' etc.'\n// → \"Lorem ipsum \\\"dolor\\\" sit \\\\'amet\\\\' etc.\"\n```\n\nIf you want to use the output as part of a CSS string literal wrapped in double quotes, set the `quotes` option to `'double'`.\n\n```js\ncssesc('Lorem ipsum \"dolor\" sit \\'amet\\' etc.', {\n 'quotes': 'double'\n});\n// → 'Lorem ipsum \\\\\"dolor\\\\\" sit \\'amet\\' etc.'\n// → \"Lorem ipsum \\\\\\\"dolor\\\\\\\" sit 'amet' etc.\"\n```\n\n#### `wrap`\n\nThe `wrap` option takes a boolean value (`true` or `false`), and defaults to `false` (disabled). When enabled, the output will be a valid CSS string literal wrapped in quotes. The type of quotes can be specified through the `quotes` setting.\n\n```js\ncssesc('Lorem ipsum \"dolor\" sit \\'amet\\' etc.', {\n 'quotes': 'single',\n 'wrap': true\n});\n// → '\\'Lorem ipsum \"dolor\" sit \\\\\\'amet\\\\\\' etc.\\''\n// → \"\\'Lorem ipsum \\\"dolor\\\" sit \\\\\\'amet\\\\\\' etc.\\'\"\n\ncssesc('Lorem ipsum \"dolor\" sit \\'amet\\' etc.', {\n 'quotes': 'double',\n 'wrap': true\n});\n// → '\"Lorem ipsum \\\\\"dolor\\\\\" sit \\'amet\\' etc.\"'\n// → \"\\\"Lorem ipsum \\\\\\\"dolor\\\\\\\" sit \\'amet\\' etc.\\\"\"\n```\n\n#### `escapeEverything`\n\nThe `escapeEverything` option takes a boolean value (`true` or `false`), and defaults to `false` (disabled). When enabled, all the symbols in the output will be escaped, even printable ASCII symbols.\n\n```js\ncssesc('lolwat\"foo\\'bar', {\n 'escapeEverything': true\n});\n// → '\\\\6C\\\\6F\\\\6C\\\\77\\\\61\\\\74\\\\\"\\\\66\\\\6F\\\\6F\\\\\\'\\\\62\\\\61\\\\72'\n// → \"\\\\6C\\\\6F\\\\6C\\\\77\\\\61\\\\74\\\\\\\"\\\\66\\\\6F\\\\6F\\\\'\\\\62\\\\61\\\\72\"\n```\n\n#### Overriding the default options globally\n\nThe global default settings can be overridden by modifying the `css.options` object. This saves you from passing in an `options` object for every call to `encode` if you want to use the non-default setting.\n\n```js\n// Read the global default setting for `escapeEverything`:\ncssesc.options.escapeEverything;\n// → `false` by default\n\n// Override the global default setting for `escapeEverything`:\ncssesc.options.escapeEverything = true;\n\n// Using the global default setting for `escapeEverything`, which is now `true`:\ncssesc('foo © bar ≠ baz 𝌆 qux');\n// → '\\\\66\\\\6F\\\\6F\\\\ \\\\A9\\\\ \\\\62\\\\61\\\\72\\\\ \\\\2260\\\\ \\\\62\\\\61\\\\7A\\\\ \\\\1D306\\\\ \\\\71\\\\75\\\\78'\n```\n\n### `cssesc.version`\n\nA string representing the semantic version number.\n\n### Using the `cssesc` binary\n\nTo use the `cssesc` binary in your shell, simply install cssesc globally using npm:\n\n```bash\nnpm install -g cssesc\n```\n\nAfter that you will be able to escape text for use in CSS strings or identifiers from the command line:\n\n```bash\n$ cssesc 'föo ♥ bår 𝌆 baz'\nf\\F6o \\2665 b\\E5r \\1D306 baz\n```\n\nIf the output needs to be a CSS identifier rather than part of a string literal, use the `-i`/`--identifier` option:\n\n```bash\n$ cssesc --identifier 'föo ♥ bår 𝌆 baz'\nf\\F6o\\ \\2665\\ b\\E5r\\ \\1D306\\ baz\n```\n\nSee `cssesc --help` for the full list of options.\n\n## Support\n\nThis library supports the Node.js and browser versions mentioned in [`.babelrc`](https://github.com/mathiasbynens/cssesc/blob/master/.babelrc). For a version that supports a wider variety of legacy browsers and environments out-of-the-box, [see v0.1.0](https://github.com/mathiasbynens/cssesc/releases/tag/v0.1.0).\n\n## Author\n\n| [](https://twitter.com/mathias \"Follow @mathias on Twitter\") |\n|---|\n| [Mathias Bynens](https://mathiasbynens.be/) |\n\n## License\n\nThis library is available under the [MIT](https://mths.be/mit) license.\n","maintainers":[{"name":"mathias","email":"mathias@qiwi.be"}],"time":{"modified":"2018-04-25T08:24:00.839Z","created":"2013-08-09T13:30:10.779Z","0.1.0":"2013-08-09T13:30:13.761Z","1.0.0":"2016-09-28T21:39:50.026Z","1.0.1":"2018-03-25T12:41:20.795Z","2.0.0":"2018-04-25T08:23:57.308Z"},"author":{"name":"Mathias Bynens","url":"https://mathiasbynens.be/"},"repository":{"type":"git","url":"git+https://github.com/mathiasbynens/cssesc.git"},"users":{"yinyongcom666":true,"maddas":true},"homepage":"https://mths.be/cssesc","keywords":["css","escape","identifier","string","tool"],"bugs":{"url":"https://github.com/mathiasbynens/cssesc/issues"},"license":"MIT","readmeFilename":"README.md","_attachments":{},"_etag":"W/\"9df83b27c91b7b6da61532f50bdc0614\"","_lastModified":"Sat, 26 May 2018 21:27:58 GMT","_cached":true}