Skip to content

Commit

Permalink
chore: Package updates, Docker build file (#987)
Browse files Browse the repository at this point in the history
* chore: bump angular version 12.0.0 -> 12.2.8

* build: remove frontend functions

* chore: update @angular/cdk 10.2.5 -> 12.2.8

* chore: update @angular/fire 6.1.1 -> 7.0.4

* chore: update fontawesome

* chore: update @nguniversal/express-engine 10.1.0 -> 12.1.1

* chore: update @angular-builders/custom-webpack 12.1.0 -> 12.1.3

* chore: update types

* chore: update eslint

* chore: fix eslint versions

* chore: fix eslint versions

* chore: update ng-in-viewport 6.1.0 -> 6.1.5

* chore: update css related packages

* fix: use firebase compat layer

* chore: update core-js 2.6.11 -> 3.18.1

* chore: remove unused lodash-es

* chore: update subsink 1.0.1 -> 1.0.2

* chore: update testing libs

* chore: remove jsdom

* chore: update tslib 2.0.1 -> 2.3.1

* chore: update @angularclass/hmr 2.1.3 -> 3.0.0

* chore: update node packages

* chore: update ngx-loading-bar

* chore: bump version

* style: format

* fix: ignore firebase type

* fix: CI

* fix: remove core-js import from tests

* build: add ssr docker building
  • Loading branch information
TwoDCube authored Nov 12, 2021
1 parent 646271c commit 2a656e8
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 22 deletions.
3 changes: 3 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
node_modules
npm-debug.log
dist
10 changes: 10 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
FROM node:14-alpine

WORKDIR /usr/src/app
COPY . .
RUN yarn install --frozen-lockfile
RUN yarn ng run frontend:build:production
RUN yarn ng run frontend:server:production

EXPOSE 4000
CMD [ "node", "dist/frontend/server/main.js" ]
19 changes: 1 addition & 18 deletions apps/frontend/src/app/app.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,18 +13,9 @@ import { NxModule } from '@nrwl/angular'
import { ActionReducer, Store, StoreModule } from '@ngrx/store'
import { StoreDevtoolsModule } from '@ngrx/store-devtools'
import { EffectsModule } from '@ngrx/effects'
import { AngularFireModule } from '@angular/fire/compat'
import { LoadersModule } from '@verseghy/ui'
import { environment } from '../environments/environment'
import { ServiceWorkerModule } from '@angular/service-worker'
import {
AngularFireAnalyticsModule,
APP_NAME,
APP_VERSION,
COLLECTION_ENABLED,
ScreenTrackingService,
} from '@angular/fire/compat/analytics'
import { AngularFirePerformanceModule } from '@angular/fire/compat/performance'
import { ToastComponent } from './components/toast/toast.component'
import { faFacebookF } from '@fortawesome/free-brands-svg-icons'
import { PageNotFoundComponent } from './components/page-not-found/page-not-found.component'
Expand Down Expand Up @@ -59,17 +50,9 @@ export const NGRX_STATE = makeStateKey('NGRX_STATE')
StoreDevtoolsModule.instrument({
maxAge: 25,
}),
AngularFireModule.initializeApp(environment.firebase),
AngularFireAnalyticsModule,
AngularFirePerformanceModule,
ServiceWorkerModule.register('ngsw-worker.js', { enabled: environment.production }),
],
providers: [
ScreenTrackingService,
{ provide: APP_NAME, useValue: 'Verseghy Honlap' },
{ provide: APP_VERSION, useValue: environment.version },
{ provide: COLLECTION_ENABLED, useValue: environment.production },
],
providers: [],
bootstrap: [AppComponent],
})
export class AppModule {
Expand Down
7 changes: 3 additions & 4 deletions apps/frontend/src/app/modules/home/services/alert.service.ts
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
import { Injectable } from '@angular/core'
import { Observable } from 'rxjs'
import { Observable, of } from 'rxjs'
import { AlertMessage } from '../models/alert-message'
import { AngularFirestore } from '@angular/fire/compat/firestore'

@Injectable({
providedIn: 'root',
})
export class AlertService {
constructor(private firestore: AngularFirestore) {}
constructor() {}

getAlertMessages(): Observable<AlertMessage[]> {
return this.firestore.collection<AlertMessage>('messages').valueChanges()
return of([])
}
}

0 comments on commit 2a656e8

Please sign in to comment.