Ionic 4 Cannot destructure property `createHash` of 'undefined' or 'null'

Hi, I’m using Ionic 4 but I have a problem, if I try to do ng serve it returns this error:

Cannot destructure property `createHash` of 'undefined' or 'null'.
TypeError: Cannot destructure property `createHash` of 'undefined' or 'null'.
    at Object.<anonymous> (/Users/andreaprimaverili/WebstormProjects/customlistingapp/node_modules/mini-css-extract-plugin/dist/index.js:21:5)
    at Module._compile (internal/modules/cjs/loader.js:702:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:713:10)
    at Module.load (internal/modules/cjs/loader.js:612:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:551:12)
    at Function.Module._load (internal/modules/cjs/loader.js:543:3)
    at Module.require (internal/modules/cjs/loader.js:650:17)
    at require (internal/modules/cjs/helpers.js:20:18)
    at Object.<anonymous> (/Users/andreaprimaverili/WebstormProjects/customlistingapp/node_modules/mini-css-extract-plugin/dist/cjs.js:3:18)
    at Module._compile (internal/modules/cjs/loader.js:702:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:713:10)
    at Module.load (internal/modules/cjs/loader.js:612:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:551:12)
    at Function.Module._load (internal/modules/cjs/loader.js:543:3)
    at Module.require (internal/modules/cjs/loader.js:650:17)
    at require (internal/modules/cjs/helpers.js:20:18)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! example@0.0.1 start: `ng serve`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the example@0.0.1 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/andreaprimaverili/.npm/_logs/2019-04-29T16_08_25_592Z-debug.log

Process finished with exit code 1

My ionic info is:

Ionic:

   ionic (Ionic CLI)             : 4.12.0 (/usr/local/lib/node_modules/ionic)
   Ionic Framework               : @ionic/angular 4.3.1
   @angular-devkit/build-angular : 0.13.8
   @angular-devkit/schematics    : 7.2.4
   @angular/cli                  : 7.3.8
   @ionic/angular-toolkit        : 1.4.1

Cordova:

   cordova (Cordova CLI) : 8.1.1 (cordova-lib@8.1.0)
   Cordova Platforms     : none
   Cordova Plugins       : no whitelisted plugins (0 plugins total)

System:

   ios-deploy : 1.9.4
   ios-sim    : 8.0.1
   NodeJS     : v10.4.1 (/usr/local/bin/node)
   npm        : 6.9.0
   OS         : macOS Mojave
   Xcode      : Xcode 10.1 Build version 10B61

Can you help me?

:wave: Hi there!

Hmm, not really sure what could be going on here. But the error points to a css plugin, which could mean you have a css error in your code. Is the project up on github? Might be worth posting a link to that or running your css through a linter to get a second pair or “eyes” on it.

Hi, Thank you for your message. Is not on GitHub but is a private BitBucket project so I can’t share it with you without your bitbucket account.
I would like to send you a pm with the link to dropbox but I can’t do it, please send me via pm your bitbucket account or the way to send you the dropbox link, thank you

Btw I think my problem is related to this one: https://stackoverflow.com/questions/50599606/callback-was-already-called-angular-cli

So when I do

sudo npm ls webpack

I have this:

And I don’t know how to remove the app-scripts webpack part to leave just the build-angular one