Questions tagged [angular-universal]

Angular Universal is a server-side rendering module for Angular applications.

Better Perceived Performance

First time users of your application will instantly see a server rendered view which greatly improves perceived performance and the overall user experience. According to research at Google, the difference of just 200 milliseconds in page load performance has an impact on user behavior.

Optimized for Search Engines

Although Googlebot crawls and renders most dynamic sites, many search engines expect plain HTML. Server-side pre-rendering is a reliable, flexible and efficient way to ensure that all search engines can access your content.

Site Preview

Ensure that Facebook, Twitter and all other social media apps correctly display a preview image of your app.

Latest Stable Version:

angular 9.x  - (February 6, 2020)

Bits

1755 questions
149
votes
12 answers

Implementing a plugin architecture / plugin system / pluggable framework in Angular 2, 4, 5, 6

Update 5/24/2018: We are now +3 versions of Angular from my original post and still don't have a final workable solution. Lars Meijdam (@LarsMeijdam) has come up with an interesting approach which is certainly worth a look-see. (Due to proprietary…
Anthony Gatlin
  • 4,407
  • 5
  • 37
  • 53
43
votes
3 answers

How to debug Angular universal?

I am using Angular Universal Starter repo. In angular 4 universal for ssr we could debug browser and node part of application in dev mode(see console), but now I do not see way to debug node part. I tried to execute ts-node server.ts with some…
dimson d
  • 1,488
  • 1
  • 13
  • 14
38
votes
9 answers

How do I import svg from file to a component in angular 5?

All tutorials with adding svg to a component in AngularCli that I found recommend to insert it in html template, something like this:
mr_blond
  • 1,586
  • 2
  • 20
  • 52
38
votes
12 answers

Update to Angular v6 - Module not found: Error: Can't resolve 'fs'

I'm trying to migrate my Angular Universal project from Angular v5 to v6 I've got a service where I use fs to load the translation on the server side. Everything works well with Angular v5. With Angular v6, when I run npm run start aka ng serve…
David Dal Busco
  • 7,975
  • 15
  • 55
  • 96
31
votes
1 answer

Angular Universal with i18n (Server Side Rendering)

I try to use Angular official internationalization tools with angular universal. So far I'm able to translate the client side rendering using the following procedure (thanks to this answer https://stackoverflow.com/a/40930110/1110635) : I add…
Stnaire
  • 1,100
  • 1
  • 18
  • 30
27
votes
1 answer

dotnet core + Angular Universal + docker => Prerendering failed because of error: Error: Cannot find module

We have a project developed using Dotnet core, Angular Universal. We use the prerender feature of Asp.net Core SPA services. In the local environment, the application works both on Windows, Linux. There some problems when using Visual Studio's own…
27
votes
5 answers

Angular-universal getting error: You must pass in a NgModule or NgModuleFactory to be bootstrapped

I converted my existing angular-cli application to angular-universal by following this guide. You can look at my complete source code here. I am able to build both browser and client projects but I get following error when I view the app in the…
Saurabh Palatkar
  • 3,242
  • 9
  • 48
  • 107
21
votes
2 answers

DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), ... methods instead

I have an angular project and recently I have added angular-universal to it using the following command: ng add @nguniversal/express-engine --clientProject {{ name of your project }} building and running it: npm run build:ssr && npm run…
Khaled Jamal
  • 628
  • 1
  • 6
  • 18
19
votes
1 answer

Server Side Rendering Angular 2 in ASP.NET with Edge.js

I'm exploring the possibility of rendering Angular 2 on the server side using Edge.js in an ASP.NET MVC application. I'm aware that the Angular Universal Starter Kit has part of this equation:…
Nicholas Westby
  • 1,109
  • 13
  • 32
18
votes
4 answers

Angular 6 Server Side Errror: Module not found: Error: Can't resolve './dist/server/main.bundle'

I'm working on a project, updating it to Angular 6. After the update, I'm now getting this error when trying to run the server-side rendering build Module not found: Error: Can't resolve './dist/server/main.bundle' I tried going to…
Jonathan Corrin
  • 1,219
  • 4
  • 17
  • 42
18
votes
1 answer

service worker and sw precache with angular universal

I used sw precache with service worker.I cached only browser folder in service worker.So that server side rendering not working in service worker.can anyone pls help me to solve this.if ssr working service worker not working and vice versa below is…
kamalav
  • 1,190
  • 4
  • 14
  • 31
18
votes
1 answer

Angular isPlatformBrowser checking against PLATFORM_ID doesn't prevent server-side pre rendering

I am trying to compile Angular 4 + ASP.NET Universal application created based on sample project here, using this hints https://github.com/angular/universal#universal-gotchas and when I build project with webpack, and then run it there is error…
Michał Ziobro
  • 10,759
  • 11
  • 88
  • 143
18
votes
3 answers

How to upload pre-rendered file on S3 and access that on initial load of our webpage?

I have my web application implemented using Angular Universal Starter kit. I want to upload the pre-rendered file to the S3 bucket so that my initial page gets loaded faster.But I couldn't find the proper configurations regarding uploading the…
17
votes
0 answers

Angular5 Server side rendering, external Api data service does not work in ssr

I have set up and used successfully Angular5 + SSR. It is still pretty nice. All components work well on SSR and Non-SSR. And there are some services which call external HTTP get APIs to get some data. Of course, it works well on a Non-SSR mode.…
Jihoon Kwon
  • 745
  • 5
  • 14
16
votes
5 answers

Update meta tags in angular universal with external API call

I've spent more than 2 months but could not found a clear solution of how to proceed with angular universal. I've already spent about 6 months in implementing angular universal on a project for which I don't get a much time and now I'm stuck with…
Black Mamba
  • 13,632
  • 6
  • 82
  • 105
1
2 3
99 100