Skip to content

Instantly share code, notes, and snippets.

Craig Wayne craigiswayne

View GitHub Profile
craigiswayne /
Last active Jul 28, 2020
How to Compile Sass \ Scss via NPM

How to Setup npm and scss \ sass

npm init
npm install node-sass --save
mkdir -p src/styles
touch src/styles/style.scss

In your generated package.json add the following to your scripts entry

craigiswayne / cssFromElement.js
Last active Apr 18, 2019
Extract all computed css from an element
View cssFromElement.js
function getAllCSS(element){
if( !element instanceof HTMLElement ){
console.warn("Select a valid HTML Element before proceeding");
return '';
let cssString = '';
const cssObj = window.getComputedStyle(element);
let cssAttributes = [];
ebidel / coverage.js
Last active Aug 13, 2019
CSS/JS code coverage during lifecycle of page load
View coverage.js
Moved to
NuroDev /
Last active Feb 9, 2020
Script to download and install Plex Media Server for Raspberry Pi
sudo apt-get update && sudo apt-get upgrade && sudo apt-get install apt-transport-https -y && wget -O - | sudo apt-key add - && echo "deb jessie main" | sudo tee /etc/apt/sources.list.d/pms.list && sudo apt-get update && sudo apt-get install -t jessie plexmediaserver && sudo rm -rf /etc/default/plexmediaserver && echo
# default script for Plex Media Server
# the number of plugins that can run at the same time
# where the mediaserver should store the transcodes
jhades / 01.ts
Last active Jul 18, 2019
ng-template, ng-container and ngTemplateOutlet examples
View 01.ts
selector: 'app-root',
template: `
<button class="tab-button"
<button class="tab-button"

Aligning images

left alignment

This is the code you need to align images to the left:

<img align="left" width="100" height="100" src="">
tatemz /
Last active Nov 2, 2019
A quick way to get a WordPress installation up and running with Docker
mkdir wordpress-site && cd wordpress-site
touch docker-compose.yml
cat > docker-compose.yml <<EOL
version: "2"
FMCorz / kodi.sql
Last active Mar 23, 2018
Find duplicate movies in Kodi
View kodi.sql
-- Find the file ~/.kodi/userdata/MyVideosXX.db
-- Open with sqlite3
-- Run the following statement:
m.c00, -- Movie name
p.strPath, -- Path
f.strFilename -- File name
FROM movie m
gokulkrishh / media-query.css
Last active Aug 6, 2020
CSS Media Queries for Desktop, Tablet, Mobile.
View media-query.css
##Device = Desktops
##Screen = 1281px to higher resolution desktops
@media (min-width: 1281px) {
hootlex /
Last active Jul 27, 2020
Run laravel project locally

##Windows users:

cmder will be refered as console

##Mac Os, Ubuntu and windows users continue here:

  • Create a database locally named homestead utf8_general_ci
You can’t perform that action at this time.