Module not found: Error: Can't resolve 'fs'

Below are the two error I’m facing
I’m using Ionic 4

I have imported Woocommerce API, but when I initialize it in constructro it shows both of this error.

You have to go to folder \node_modules@angular-devkit\build-angular\src\angular-cli-files\models\webpack-configs\browser.js and replace node: false, by node: { crypto: true, stream: true, fs: “empty”, net: “empty”, tls: “empty” },
It’s working for me.