Skip to content

Instantly share code, notes, and snippets.

View nhathiwala's full-sized avatar

Nayan Hathiwala nhathiwala

View GitHub Profile
@nhathiwala
nhathiwala / home.component.ts
Last active November 6, 2023 07:23
SEO Service for Angular 4+ | Example for SeoService: https://gist.github.com/nhathiwala/7aec328fdf129393389f826c7f5f2943
import { Component, OnInit } from '@angular/core';
import { SeoService } from '../../services/seo.service';
@Component({
selector: 'app-home',
templateUrl: './home.component.html',
styleUrls: ['./home.component.scss']
})
export class HomeComponent implements OnInit {
@nhathiwala
nhathiwala / seo.service.ts
Last active February 9, 2019 15:38
SEO Service for Angular 4+
import { Injectable } from '@angular/core';
import { Meta, Title } from '@angular/platform-browser';
export interface TypingSEO {
title?: string;
titleSuffix?: string;
description?: string;
image?: string;
keywords?: string;
url?: string;
@nhathiwala
nhathiwala / index.ts
Created August 12, 2017 21:14
firefunctions/src/models/index.ts
/*
* FILE NAME: index.ts
* FILE PATH: './models/'
* AUTHOR: NAYAN HATHIWALA
* CREATED ON: 10/8/2017
* DESCRIPTION: BASE Model.
*/
/*
@nhathiwala
nhathiwala / index.ts
Created August 12, 2017 20:05
firefunctions/src/index.ts
/*
* FILE NAME: index.ts
* FILE PATH: './'
* AUTHOR: NAYAN HATHIWALA
* CREATED ON: 10/8/2017
* DESCRIPTION: MAIN INDEX.
*/
import * as functions from 'firebase-functions'
import * as admin from 'firebase-admin'
import * as express from 'express'
@nhathiwala
nhathiwala / index.ts
Created August 12, 2017 07:39
firefunctions/src/triggers/index.ts
/*
* FILE NAME: index.ts
* FILE PATH: './triggers/'
* AUTHOR: NAYAN HATHIWALA
* CREATED ON: 10/8/2017
* DESCRIPTION: BASE TRIGGER.
*/
/*
* IMPORT LIBRARY HERE
@nhathiwala
nhathiwala / index.ts
Created August 12, 2017 06:26
firefunctions/src/api/index.ts
/*
* FILE NAME: index.ts
* FILE PATH: './api/'
* AUTHOR: NAYAN HATHIWALA
* CREATED ON: 10/8/2017
* DESCRIPTION: BASE API.
*/
/*
* IMPORT LIBRARY HERE
@nhathiwala
nhathiwala / index.ts
Last active August 12, 2017 05:52
firefunctions/src/lib/index.ts
/*
* FILE NAME: index.ts
* FILE PATH: './lib/'
* AUTHOR: NAYAN HATHIWALA
* CREATED ON: 10/8/2017
* DESCRIPTION: All necessary library initialization are to be done in this file.
*/
// IMPORT LIBRARY HERE
const googleCloudDatastore = require('@google-cloud/datastore')({