Reputation: 109
I am following this tutorial https://blog.angular-university.io/angular-universal/ but I couldn't execute the first command
ng generate universal --client-project -the name of your client project-
the error is
Target name already exists.
any suggestions or if anyone has a better solution to implement angular universal on an existing angular project?
Upvotes: 2
Views: 4002
Reputation: 31
In my case, I already had server object in angular.json. I mean in projects.[project name]. architect.server Just remove it, if it unnecessary for you, and command will work
Upvotes: 1
Reputation: 234
Run this command as shown above StepUp
ng generate universal --client-project=
application-name
where <application_name>
is the name you can find in your package.json (example)
Here, I'll run
ng generate universal --client-project=client
Upvotes: 0
Reputation: 38094
Try to run your command like this with =
sign:
ng generate universal --client-project=YourApplicationName
Upvotes: 5