question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

angular pwa install fails

See original GitHub issue

i have added the pwa with npm install @angular/pwa --save-dev nx g @angular/pwa:ng-add --project *project-name*

in my project setup i have a folder structure with a folder apps which has 4 separate applications each having their own index.html and environments etc i want to add pwa support to one of the projects in that structure but i am receiving this error

>  NX  Generating @angular/pwa:ng-add

[NX] Angular devkit readJsonWorkspace fell back to Nx workspaces logic
Workspace extension with invalid name (targetDependencies) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
[NX] Angular devkit called `writeWorkspace`, this may have had unintended consequences in angular.json
[NX] Double check angular.json before proceeding
[NX] Angular devkit readJsonWorkspace fell back to Nx workspaces logic
Workspace extension with invalid name (targetDependencies) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
Project extension with invalid name (files) found.
TypeError: this.host.readText is not a function
    at new JSONFile

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:13 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
Kevin-Terblanchecommented, Oct 12, 2022

i pulled all the newest changes and was still getting the same error i downgraded my pwa version to @13.3.9 to be compatible with current angular version else the error gets throws where you could try use --legacy-peer-deps to fix so just downgraded the version seems to now go though and not give that same issue any more now sitting with this issue

`> NX Generating @angular/pwa:ng-add

[NX] Angular devkit called writeWorkspace, this may have had unintended consequences in angular.json [NX] Double check angular.json before proceeding SchematicsException [Error]: Could not read file (/apps/spreekuur/src/undefined.ts).

NX Could not read file (/apps/spreekuur/src/undefined.ts).

Pass --verbose to see the stacktrace. `

1reaction
Coly010commented, Oct 12, 2022
Read more comments on GitHub >

github_iconTop Results From Across the Web

Adding @angular/pwa not working on angular CLI
5 Answers 5 · Uninstall the cli: npm uninstall -g angular-cli · Clear the npm cache: npm cache verify · Reinstall the angular...
Read more >
Error on ng add @angular/pwa · Issue #10469 - GitHub
Observed behavior. $ ng add @angular/pwa Installing packages for tooling via npm. npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.2 ...
Read more >
Angular PWA, install and configure - DEV Community ‍ ‍
1. Create an Angular application · 2. Add @angular/pwa package · 3. Understand the files added/modified by @angular/pwa package · 4. Run the ......
Read more >
ng add @angular/pwa issues : r/Angular2 - Reddit
Attempting to deploy an Angular/Ionic PWA project via a CI/CD pipeline, which passes fine but visiting the site reveals following error: Failed ......
Read more >
@angular/pwa - npm
Enables service worker builds in the Angular CLI. Imports and registers the service worker in the app module. Adds a web app manifest....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found