postcss-selector-parser icon indicating copy to clipboard operation
postcss-selector-parser copied to clipboard

TypeError: Cannot read property '_run' of undefined

Open jonathantneal opened this issue 7 years ago • 0 comments

The following code:

import parser from 'postcss-selector-parser';
const { process } = parser();

process('button:not([disabled])');

Produces the following error:

TypeError: Cannot read property '_run' of undefined
    at process (/test/node_modules/postcss-selector-parser/dist/processor.js:162:21)
    at /test/index.mjs:4:1
    at ModuleJob.run (internal/modules/esm/module_job.js:106:14)

While the following code produces no error:

import parser from 'postcss-selector-parser';
const processor = parser();

processor.process('button:not([disabled])');

Perhaps this should be documented?

jonathantneal avatar May 30 '18 23:05 jonathantneal