mirror of
https://github.com/aspnet/JavaScriptServices.git
synced 2025-12-26 03:27:30 +00:00
Example of using asp-prerender-data to get server-supplied data to both server and client JS
This commit is contained in:
@@ -14,7 +14,8 @@ import { sharedConfig } from './app.module.shared';
|
||||
...sharedConfig.imports
|
||||
],
|
||||
providers: [
|
||||
{ provide: 'ORIGIN_URL', useValue: location.origin }
|
||||
{ provide: 'ORIGIN_URL', useValue: location.origin },
|
||||
{ provide: 'PRERENDERING_DATA', useValue: (window as any).PRERENDERING_DATA }
|
||||
]
|
||||
})
|
||||
export class AppModule {
|
||||
|
||||
Reference in New Issue
Block a user