Ionic serve | Node packages may not be installed

$ ionic serve

ng.cmd run app:serve --host=localhost --port=8100
[ng] Node packages may not be installed. Try installing with ‘npm install’.
[ng] Could not find the ‘@angular-devkit/build-angular:dev-server’ builder’s node package.

[ERROR] ng has unexpectedly closed (exit code 1).

    The Ionic CLI will exit. Please check any output above for error details.

I what to open an Ionic source code on my PC, but got this error can anybody tell me what do I miss here?

After installing npm, got this:

$ ionic serve
> ng.cmd run app:serve --host=localhost --port=8100
[ng] An unhandled exception occurred: Cannot find module 'C:\ionic-course\AppSourceCodeIonic\node_modules\array-flatten\dist\index.js'. Please verify that the package.json has a valid "main" entry
[ng] See "C:\Users\96897\AppData\Local\Temp\ng-nq1Ha8\angular-errors.log" for further details.

[ERROR] ng has unexpectedly closed (exit code 127).```

Need you help please.