Skip to content

Instantly share code, notes, and snippets.

Avatar
🏠
Working from home

Jasper Frumau jasperf

🏠
Working from home
View GitHub Profile
@jasperf
jasperf / rcWidget.js
Created May 19, 2020 — forked from milesw/rcWidget.js
rcWidget.js
View rcWidget.js
import 'core-js/es6/array';
import 'core-js/es6/object';
import 'core-js/es6/string';
// Global options
import defaults from './_config';
// general helper functions
import Helper from './_helpers';
// general pricing and currency functions
import Pricing from './_pricing';
// throttle and debounce manager
@CodingMonkTech
CodingMonkTech / Configurations for Laravel app on Kubernetes - Dockerfile
Last active Sep 22, 2021
Deploying laravel on kubernetes cluster - Ready to use configuration Files
View Configurations for Laravel app on Kubernetes - Dockerfile
FROM php:7.2-fpm
COPY app /var/www/
EXPOSE 9000
View laravel-vscode-settings.json
{
"editor.formatOnSave": false,
"javascript.format.enable": true,
"eslint.autoFixOnSave": true,
"vetur.format.defaultFormatter.html": "prettyhtml",
"eslint.alwaysShowStatus": true,
"eslint.options": {
"extensions": [".html", ".js", ".vue", ".jsx"]
},
"eslint.validate": [
@mul14
mul14 / index.js
Created Jul 25, 2018
JavaScript DocBlock Cheat Sheet
View index.js
/**
* Description of this function.
*
* @param {string} name
* @param {Date} birthday
* @param {boolean=} isMarried Optional parameter.
* @param {string|null} [bloodType]
* @param {number=} [weight=0] Optional parameter with default value.
* @param {string[]} favoriteFoods Array of String.
*
@frank-dspeed
frank-dspeed / create_sftp_user.sh
Last active Feb 28, 2018
Setup SFTP Only users
View create_sftp_user.sh
#!/bin/bash
#Setup SFTP Group and Service
function setup(){
#Create sftpusers group.
sudo groupadd sftpusers
#Comment out setting disabling SFTP access from sshd config file.
sudo sed -i "s/Subsystem sftp \/usr\/lib\/openssh\/sftp-server/#Subsystem sftp \/usr\/lib\/openssh\/sftp-server/" /etc/ssh/sshd_config
@welcoMattic
welcoMattic / imagemin.md
Last active Sep 20, 2021
How to fix `Error: spawn ./node_modules/jpegtran-bin/vendor/jpegtran ENOENT` error for imagemin
View imagemin.md

If you're trying to run imagemin (from grunt or gulp or anything else) on Alpine, you certainly had to meet this error :

Error: spawn /YOUR_PROJECT_PATH/node_modules/jpegtran-bin/vendor/jpegtran ENOENT or the same with optipng or gifsicle instead of jpegtran.

Here's how to solve it.

First you need to install on Alpine missing package used to compile jpegtran, gifsicle and optipng binaries. Those packages are (at least):

autoconf automake file build-base nasm musl libpng-dev zlib-dev

@dikaio
dikaio / default.conf
Last active Jul 20, 2021
Sample Nginx Laravel Server Block
View default.conf
server {
listen 80 default_server;
root /var/www/laravel/public;
index index.php index.html index.htm;
server_name _;
location / {
try_files $uri $uri/ /index.php$is_args$args;
}
location ~ \.php$ {
try_files $uri /index.php = 404;
@smutek
smutek / content-page.blade.php
Last active Jul 6, 2020
Simple Sage 9 Slider with Slick
View content-page.blade.php
@php(the_content())
@if($images)
@include('partials/slider')
@endif
@adamwathan
adamwathan / troubleshooting.md
Last active Jan 19, 2021
Troubleshooting Valet on macOS Sierra
View troubleshooting.md

Troubleshooting Valet on Sierra

Common Problems

Problem: I just see "It works!"

Apache is running on port 80 and interfering with Valet.

  1. Stop Apache: sudo /usr/sbin/apachectl stop
  2. Restart Valet: valet restart