An error was reported when the Grunt css compression plug-in was executed.

  node.js, question

The first contact with GRUNT configuration was based on the book, but it was always reported wrong when it was executed. Baidu has found many similar problems for a long time, but still no feasible solution has been found.
Json code:

bracket
 "name":"CSS_ZIP",
 "description":"css compressor",
 "engines":{
 "node":">=0.8.0"
 },
 "dependencies":{
 "grunt":"~0.4.2",
 "grunt-contrib-cssmin":"x"
 bracket
 bracket

Js code:

module.exports=function(){
 //configuration
 grunt.initConfig({
 pkg: grunt.file.readJSON('package.json'),
 cssmin:{
 options:{
 keepSpecialComments:0
 },
 compress:{
 files:{
 "css/min/main-min.css":[
 "css/*.css"
 bracket
 bracket
 bracket
 bracket
 });
 //Load css Compression Plug-ins
 grunt.loadNpmTasks('grunt-contrib-cssmin');
 //Registration Task
 grunt.registerTask('default',['cssmin']);
 bracket

The order of my execution is as follows:
1. First install the plug-in in the current project (perform npm install)
插件安装执行命令结果图

2. then execute grunt’s command
grunt插件执行命令结果图

You can clearly see the wrong bird. . . . . , found a lot of answers online, such as:
1. Delete the original node_modules, and then execute npm install (Planking)
2. It is possible that the installation of grunt plug-in is incomplete and cannot be found. Remove and reinstall grunt (Planking)
3. The installed grunt is not global. Remove the original GRUNT and install it according to the global method (Planking)
Wait …
The list of the above-mentioned problems only shows that I have really been to Baidu. Therefore, please objectively stop despising me.

module.exports=function(grunt){}

Add grunt to parameter inside