Skip to content

Instantly share code, notes, and snippets.

View reinvanoyen's full-sized avatar
🌒
...

Rein Van Oyen reinvanoyen

🌒
...
View GitHub Profile
@reinvanoyen
reinvanoyen / scrape-text-from-sitemap.js
Last active February 7, 2024 08:49
scrape-text-from-sitemap
"use strict";
const https = require('https');
const Sitemapper = require('sitemapper');
const jsdom = require('jsdom');
const fs = require('fs');
const { JSDOM } = jsdom;
if (!process.argv[2]) {
@reinvanoyen
reinvanoyen / marquee.js
Created February 6, 2020 16:31
Vanilla marquee
"use strict";
export default class Marquee {
constructor(el, speed) {
this.el = el;
this.scrollEl = this.el.querySelector('.marquee__scroll');
this.itemsEl = this.el.querySelector('.marquee__items');
this.speed = speed;
@reinvanoyen
reinvanoyen / terminal-prompt-git-branch-zsh.md
Last active April 12, 2024 22:18
Add Git Branch Name to Terminal Prompt (MacOS zsh)

Add Git Branch Name to Terminal Prompt (zsh)

Updated for MacOS with zsh

  • Catalina
  • Big Sur
  • Monterey
  • Ventura
  • Sonoma

screenshot

@reinvanoyen
reinvanoyen / class-example.js
Created March 10, 2017 16:04
Simple Javascript class system with inheritance and property/method visibility (public/private)
"use strict";
const module = function( f ) {
let pub = {};
f( pub );
return pub;
};
const Class = {
create: function( data ) {