postcss-normalize-string
Normalize wrapping quotes for CSS string literals.
Last updated 7 years ago by evilebottnawi .
MIT · Repository · Bugs · Original npm
$ cnpm install postcss-normalize-string 
SYNC missed versions from official npm registry.

postcss-normalize-string

Normalize strings with PostCSS.

Install

With npm do:

npm install postcss-normalize-string --save

Example

Input

p:after{ content: '\\'string\\' is intact' }

Output

p:after{ content:"'string' is intact" }

Usage

See the PostCSS documentation for examples for your environment.

API

normalize([options])

options

preferredQuote

Type: string Default: double

Sets what type of quote to prefer. Possible values are single and double.

var css = 'p:after{content:""}';
console.log(postcss(normalize({preferredQuote: 'single'})).process(css).css);
//=> p:after{content:''}

Contributors

See CONTRIBUTORS.md.

License

MIT © Ben Briggs

Current Tags

  • 6.0.0                                ...           latest (2 years ago)

9 Versions

  • 6.0.0                                ...           2 years ago
  • 5.1.0                                ...           3 years ago
  • 5.0.3                                ...           4 years ago
  • 5.0.2                                ...           4 years ago
  • 5.0.1                                ...           4 years ago
  • 4.0.0-nightly.2020.2.6                                ...           5 years ago
  • 5.0.0-rc.2                                ...           4 years ago
  • 5.0.0                                ...           4 years ago
  • 4.0.2                                ...           7 years ago
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (3)
Dev Dependencies (2)
Dependents (0)
None

Copyright 2013 - present © cnpmjs.org