Skip to content

Instantly share code, notes, and snippets.

View trev-dev's full-sized avatar
:electron:
Free as in Freedom

Trev trev-dev

:electron:
Free as in Freedom
View GitHub Profile
@trev-dev
trev-dev / Original.css
Last active January 15, 2018 02:39
Media Query Troubles
/*
Styles only apply to 1224px wide, if we go below that, these styles stop applying.
If we fall below 1224px wide, suddenly all of our header styles disappear, which is bad news bears for us.
*/
@media only screen and (min-width : 1224px) {
h3 { margin: 50px auto; }
h3:first-child { margin-top: 0; }
header{
background-color:#f3f2f5;
@trev-dev
trev-dev / app.js
Last active November 16, 2017 00:57
Image upload example
var express = require('express');
var config = require('./modules/config');
var routes = require('./modules/routes'); // Using all routes as an exported function. See routes.js.
var db = require('./modules/db.js');
var app = express();
app.set('view engine', 'pug');
app.use('/form', express.static(`${__dirname}/static`));
app.use('/form/form', express.static(`${__dirname}/static`));
@trev-dev
trev-dev / variants.js
Created October 4, 2017 03:47
Variant Breakdown
current.product.variants = [{option1: 'Normal'}, {option1: 'Foil'}]; // Original Code
// Lets make some white space to make this easier ;) - then we're going to add our missing parameters.
current.product.variants = [
{
option1: 'Normal',
inventory_quantity: 0,
inventory_management: 'shopify'
},
@trev-dev
trev-dev / precompiled.sass
Created August 3, 2017 00:16
Sassy example
.wrapper
+grid-container
width: 960px
max-width: 100%
margin: 0 auto
.form-top
+grid-column
text-align: center
@trev-dev
trev-dev / compiled.css
Created August 3, 2017 00:13
Sass + autoprefix compiled
.wrapper {
width: 960px;
max-width: 100%;
margin: 0 auto;
}
.wrapper::after {
clear: both;
content: "";
display: block;