Skip to content

Instantly share code, notes, and snippets.

View m-goos's full-sized avatar

Marc m-goos

View GitHub Profile
@m-goos
m-goos / online-privacy-is-finally-cool-so-where-to-start.md
Created June 6, 2021 11:37
Online privacy is finally cool, so.. where to start?

Reading about privacy is like reading about conspiracy theories. What you read seems improbable, dystopian and kind of crazy. However, the difference between some random conspiracy theory and the case of our online privacy, is that those dystopian stories about our privacy are not fiction - they are actually true! With everything we do on the internet, we share information about ourselves, and most of us have no clue how this information is being used.

Why even ‘Big Tech’ calls for action

Now I wouldn’t be surprised if you saw Netflix’s The Social Dilemma in the past year, a (very dramatic) documentary that shows us the dark side of social media and big tech. From the people that created the 👍 Like button at Facebook, to the behavioral scientists that made Instagram as addictive as possible, we hear how things go behind the scenes. How all our data is analyzed to predict our behavior, how elections are being manipulated and how our attention is being sold. Nothing new apparently, and if this left you fee

How to: build a blog with Angular 11, Markdown, Bootstrap 5 and the AWS Cloud (S3)

With this post I would like to share with you how you can setup your own blogging website from scratch, within an Angular 11 project. My goal is to show you how the following technologies work together: Angular 11, Bootstrap 5, AWS S3 (cloud storage) and Markdown. This post guides you in adding the simple blogging functionality with a very clean look.

Together with you I will set up the blogging module for your website, style it and host it in the AWS cloud, in a so-called S3 bucket for static website hosting. The blogs will be written in Markdown, a highly portable markup format, that I use often. With this setup, I can post my writings on Techspire.nl, to Techspire's Medium account and to my own blog with minimal editing. And that is just great!

If one of these technologies might be new to you:

  • Bootstrap is a markup framework for building
@m-goos
m-goos / blog.module.ts
Created January 28, 2021 10:00
The module for an Angular blog based on MarkDown files
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { RouterModule } from '@angular/router';
import { MarkdownModule } from 'ngx-markdown';
import { HttpClient, HttpClientModule } from '@angular/common/http';
import { EntryListComponent } from './entry-list/entry-list.component';
import { PostComponent } from './post/post.component';
@NgModule({
/*
credits and thanks to John Othander: https://github.com/johno
this css is copied and minimally modified from https://github.com/markdowncss/splendor/blob/master/css/splendor.css
on jan 27, 2021
*/
@media print {
*,
*:before,
*:after {
background: transparent !important;

How I got up to speed in Angular

Learnings from my first month in Angular

Consider this article as a suggested roadmap for learning Angular, where the goal is to get familiar with the most important concepts in Angular, fast. For my first month working with Angular, I wrote down the resources I used. This article will save you the search for the right resources in an unknown landscape as I provide you some guidelines. That makes this article relevant:

  • if you want to get started with Angular yourself,
  • if you want a high-level overview of Angular concepts to compare it to React or to your view on Angular or
  • if you simply want to supplement your current learning with additional resources.

Let's get started, hop on the Angular train!

|Hop on|

@m-goos
m-goos / keybindings.json
Last active October 23, 2020 15:36
VS Code keybindings.json settings
// inspired by https://stackoverflow.com/questions/38957302/is-there-a-quick-change-tabs-function-in-visual-studio-code
// Place your key bindings in this file to override the defaults
[
{
"key": "ctrl+tab",
"command": "workbench.action.nextEditor"
},
{
"key": "ctrl+shift+tab",
"command": "workbench.action.previousEditor"
@m-goos
m-goos / settings.json
Created October 23, 2020 15:21
VS Code settings.json
{
"files.autoSave": "afterDelay",
"editor.wordWrap": "on",
"window.zoomLevel": 1,
"explorer.confirmDelete": false,
"editor.tabSize": 2,
"explorer.confirmDragAndDrop": false,
"editor.minimap.enabled": false,
"javascript.updateImportsOnFileMove.enabled": "always",
"typescript.updateImportsOnFileMove.enabled": "always"
@m-goos
m-goos / server.js
Last active October 19, 2020 16:39
Express boilerplate
// 1. In the terminal: add express to the project: npm i express --save
// 2. In project root: create server.js and paste in this code
// 3. In package.json: change the 'start' script to "start": "node server.js",
// to test, run: ng build && npm start, then go to localhost:port
const express = require('express');
const app = express();
const port = (process.env.PORT || 8080);
// find the app name in package.json
# nano ~/.zshrc -> paste from line 5 onwards -> save (ctrl + o) -> exit (ctrl + x)
# source ~/.zshrc -> YES
# compaudit | xargs chmod g-w
# Tab completion
autoload -Uz compinit && compinit
# Bash completion
autoload bashcompinit && bashcompinit