Skip to content

Instantly share code, notes, and snippets.

View leenorshn's full-sized avatar
🏠
Working from home

Victor Shukuru leenorshn

🏠
Working from home
View GitHub Profile
@leenorshn
leenorshn / main.go
Created October 17, 2022 15:25 — forked from julz/main.go
containersched minicontainer
package main
import (
"fmt"
"os"
"os/exec"
"syscall"
)
func main() {
@leenorshn
leenorshn / instructions.md
Created April 27, 2021 10:55 — forked from WesThorburn/instructions.md
Use Chart.js with Nuxt v2.11.0

Use Chart.js with Nuxt v2.11.0

Line chart example

  • Run npm i vue-chartjs
  • Run npm i chart.js hchs-vue-charts
  • Create a file called chart.js and save it in the /plugins directory
  • Give chart.js the following contents
import Vue from 'vue'
import { Line } from 'vue-chartjs'
@leenorshn
leenorshn / app.js
Created September 8, 2020 13:15 — forked from hugosp/app.js
Minimal express-ws broadcast to all clients
var express = require('express');
var expressWs = require('express-ws');
var expressWs = expressWs(express());
var app = expressWs.app;
app.use(express.static('public'));
var aWss = expressWs.getWss('/');
app.ws('/', function(ws, req) {