Skip to content

Instantly share code, notes, and snippets.

View HansS's full-sized avatar
🎯
Focusing

Hans Schenker HansS

🎯
Focusing
View GitHub Profile
@HansS
HansS / entity-feature-store-module-actions.ts
Last active June 14, 2018 13:21 — forked from wesleygrimes/entity-feature-store-module-actions.ts
ngrx-01 Entity Feature Store Module - Actions
import { Action } from '@ngrx/store';
import { MyModel } from '../../models';
export enum ActionTypes {
LOAD_REQUEST = '[My Feature] Load Request',
LOAD_FAILURE = '[My Feature] Load Failure',
LOAD_SUCCESS = '[My Feature] Load Success'
}
export class LoadRequestAction implements Action {
@HansS
HansS / webpack.config-for-ts.js
Created May 14, 2018 09:12
Webpack Config Template for Typescript
module.exports = {
mode: "development",
devtool: "inline-source-map",
entry: "./app.ts",
output: {
filename: "bundle.js"
},
resolve: {
// Add `.ts` and `.tsx` as a resolvable extension.
extensions: [".ts", ".tsx", ".js"]
@HansS
HansS / webpack.config-for-ts.js
Created May 14, 2018 09:12
Webpack Config Template for Typescript
module.exports = {
mode: "development",
devtool: "inline-source-map",
entry: "./app.ts",
output: {
filename: "bundle.js"
},
resolve: {
// Add `.ts` and `.tsx` as a resolvable extension.
extensions: [".ts", ".tsx", ".js"]
@HansS
HansS / webpack.config-for-ts.js
Created May 14, 2018 09:12
Webpack Config Template for Typescript
module.exports = {
mode: "development",
devtool: "inline-source-map",
entry: "./app.ts",
output: {
filename: "bundle.js"
},
resolve: {
// Add `.ts` and `.tsx` as a resolvable extension.
extensions: [".ts", ".tsx", ".js"]
@HansS
HansS / GCalUtils.md
Created May 11, 2018 09:32 — forked from mogsdad/GCalUtils.md
Collection of Google Calendar related utility functions for Google Apps Script.

Google Calendar Utilities

getEventsWithGuest

Gets all events that occur within a given time range, and that include the specified guest email in the guest list.

###Parameters:###

@HansS
HansS / GCalUtils.md
Created May 11, 2018 09:32 — forked from mogsdad/GCalUtils.md
Collection of Google Calendar related utility functions for Google Apps Script.

Google Calendar Utilities

getEventsWithGuest

Gets all events that occur within a given time range, and that include the specified guest email in the guest list.

###Parameters:###

@HansS
HansS / googleServices.js
Created May 11, 2018 09:18 — forked from auser/googleServices.js
Part of the code for the Beginner's Guide to AngularJS
'use strict';
var __gapiAvailable = function() {
return typeof(gapi) !== 'undefined';
}
angular.module('myApp.services', [])
.value('version', '0.0.1');
// Our google services module
@HansS
HansS / gcal.html
Created May 10, 2018 06:37 — forked from danesparza/gcal.html
Google client side calendar API
<html>
<head>
<script type="text/javascript">
/*
Sample code taken shamelessly (and modified)
from https://developers.google.com/google-apps/calendar/quickstart/js
*/
// Your Client ID can be retrieved from your project in the Google
// Developer Console, https://console.developers.google.com
/**
* @license
* Copyright 2018, Google, Inc.
* Licensed under the Apache License, Version 2.0 (the 'License');
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
@HansS
HansS / google-calendar-read-js
Created May 9, 2018 06:51 — forked from marchawkins/google-calendar-read-js
How to connect to the Google Calendar API via the Javascript Client Library to retrieve calendar events. The demo also employs Oauth2 authentication, so the script could read a logged in user's calendar. This demo **only** reads a public calendar. You need the calendar's id (from google) in your own code to retrieve any events. For more info, vi…
<div class="row">
<div class="col-md-2 col-sm-2 col-xs-12">
<button id="authorize-button" style="visibility: hidden" class="btn btn-primary">Authorize</button>
</div><!-- .col -->
<div class="col-md-10 col-sm-10 col-xs-12">
<script type="text/javascript">
// date functions
Date.prototype.getWeek = function(start) {
start = start || 0;