north.inhale
north.inhale

Reputation: 511

Local Npm module "autoprefixer-core" not found. Is it installed?

Can't really fix it. I deleted node_modules folder many times. Also tried to replace: grunt.loadNpmTasks('/var/www/XXX/public/node_modules/autoprefixer-core');

=> instead =>

grunt.loadNpmTasks('autoprefixer-core');

But nothing helps. However, fanny moment my code is working: enter image description here

I mean autoprefix-core is working

But somehow giving error. =(

Please HELP!

Upvotes: 2

Views: 790

Answers (1)

Pete TNT
Pete TNT

Reputation: 8403

You require the module yourself inside the processor-configuration while passing the object with browsers to the module similar to how you would require regular node-modules.

In your Gruntfile, you have this:

processors: [
    require('autoprefixer-core')({
      browsers: [
         '> 11%',
         'Chrome >= 10',
         'Explorer >= 6',
         'Opera >= 11',
         'Firefox >= 3.5',
         'Safari >= 4',
         'iOS >= 6'
        ],
        remove: true
     })
]

So you don't actually need this as it's not really an task (thus the error):

grunt.loadNpmTasks('autoprefixer-core');

So you can safely remove that line from your config.

Upvotes: 4

Related Questions