Skip to content

Commit

Permalink
Merge pull request #6 from rollthecloudinc/tz-2-forms-demo-panel-page…
Browse files Browse the repository at this point in the history
…-rendering-twice

[tz-2] Revert all the previous changes to try and fix duplicate rende…
  • Loading branch information
ng-druid authored Jul 13, 2024
2 parents da860e6 + d30cbd0 commit 8f88879
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 9 deletions.
3 changes: 0 additions & 3 deletions angular.json
Original file line number Diff line number Diff line change
Expand Up @@ -233,8 +233,5 @@
}
}
}
},
"cli": {
"analytics": false
}
}
5 changes: 2 additions & 3 deletions projects/spear/src/app/app.module.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { BrowserModule, provideClientHydration /*, BrowserTransferStateModule */ } from '@angular/platform-browser';
import { NgModule, APP_INITIALIZER, SecurityContext, PLATFORM_ID, APP_ID } from '@angular/core';
import { NgModule, APP_INITIALIZER, SecurityContext, PLATFORM_ID } from '@angular/core';
import { CommonModule } from '@angular/common';
import { HttpClientModule, HTTP_INTERCEPTORS, HttpClientJsonpModule } from '@angular/common/http';
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
Expand Down Expand Up @@ -91,7 +91,7 @@ export function markedOptionsFactory(): MarkedOptions {
@NgModule({
declarations: [AppComponent ],
imports: [
BrowserModule,
BrowserModule.withServerTransition({ appId: 'serverApp' }),
CommonModule,
HttpClientModule,
HttpClientJsonpModule,
Expand Down Expand Up @@ -169,7 +169,6 @@ export function markedOptionsFactory(): MarkedOptions {
providers: [
provideClientHydration(),
CatchAllGuard,
{ provide: APP_ID, useValue: 'serverApp' },
{ provide: SITE_NAME, useValue: environment.site },
{ provide: CLIENT_SETTINGS, useValue: new ClientSettings(environment.clientSettings) },
{ provide: MEDIA_SETTINGS, useValue: new MediaSettings(environment.mediaSettings) },
Expand Down
5 changes: 2 additions & 3 deletions projects/spear/src/app/app.server.module.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
import { NgModule } from '@angular/core';
import { ServerModule } from '@angular/platform-server';
import { ServerModule, ServerTransferStateModule } from '@angular/platform-server';
import { FlexLayoutServerModule } from '@angular/flex-layout/server';

import { AppModule } from './app.module';
import { AppComponent } from './app.component';
import { HOST_NAME, PROTOCOL } from '@rollthecloudinc/utils';
import { APP_BASE_HREF } from '@angular/common';
import { provideClientHydration } from '@angular/platform-browser';
// import { Log } from 'oidc-client';

//Log.logger = console;
Expand All @@ -16,11 +15,11 @@ import { provideClientHydration } from '@angular/platform-browser';
imports: [
AppModule,
ServerModule,
ServerTransferStateModule,
FlexLayoutServerModule
],
bootstrap: [AppComponent],
providers: [
provideClientHydration()
/* These are required only for pre-rendering - quick hack to make work for now */
// { provide: APP_BASE_HREF, useValue: 'http://localhost:4000/' },
//{ provide: HOST_NAME, useValue: 'g6cljn4j35.execute-api.us-east-1.amazonaws.com' },
Expand Down

0 comments on commit 8f88879

Please sign in to comment.