NV / CSSOM

Unmaintained! ⚠️ CSS Object Model implemented in pure JavaScript. Also, a CSS parser.

Home Page:https://nv.github.io/CSSOM/docs/parse.html

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

parseError on @media print {

przemyslawjanpietrzak opened this issue · comments

const cssom = require("cssom"); //version 0.4.4

const styles = `@-moz-document url-prefix(){@media print{.enabled-vuetify-global-styling .v-application,.enabled-vuetify-global-styling .v-application--wrap{display:block}}}`;

cssom.parse(styles);

throws

Uncaught Error: Unexpected } (line 1, char 157)
    at parseError (/Users/przemyslawbeigert/code/bethink/wnl-platform/node_modules/cssom/lib/parse.js:62:15)
    at Object.parse (/Users/przemyslawbeigert/code/bethink/wnl-platform/node_modules/cssom/lib/parse.js:386:7) {
  line: 1,
  char: 157,
  styleSheet: CSSStyleSheet {
    parentStyleSheet: null,
    cssRules: [ [CSSMediaRule] ]
  }
}