Skip to content

Instantly share code, notes, and snippets.

View thisislawatts's full-sized avatar

Luke Watts thisislawatts

View GitHub Profile
@thisislawatts
thisislawatts / swagger.yml
Last active November 19, 2017 17:25
Vertoe FYA integration
swagger: '2.0'
info:
description: >-
This is a sample of how Vertoe could integrate with FYA. Using the Swagger
spec, find out more at [http://swagger.io](http://swagger.io) or on
[irc.freenode.net, #swagger](http://swagger.io/irc/)
version: 1.0.0
title: FYA with Vertoe
contact:
email: luke@thisis.la
@thisislawatts
thisislawatts / ftl.js
Created July 13, 2017 13:00
Copy fractal components across to Shopify Theme snippets/
/* */
const fs = require("fs");
const recursive = require("recursive-readdir");
recursive(__dirname + "/src/components/", [
"preview.liquid",
".DS_Store",
"*.json"
]).then(files => {
<p>We offer the opportunity to develop your career in a sociable, design driven practice, working on prestigious projects for
well-known clients. Pitman Tozer Architects is a great place to work, with a growing studio of 20 and an office move to
Marylebone planned in April 2017. We offer a number of benefits including pension contributions and annual office trip
abroad. </p>
<p>We are currently recruiting for the following:</p>
<p>Part-time graphic designer<br>
<br> We are seeking a talented graphic designer to join our growing London design studio on a part time basis of three
days a week.</p>
@thisislawatts
thisislawatts / Description.html
Last active April 3, 2017 10:03
Flags for BRM
<!-- Insert the following before the French text -->
<img width="15" src="//hosted.bcmh.build/basecamp/assets/flag-fr.svg"/><br/>
<!-- Insert the following before the English text -->
<br/><img width="15" src="//hosted.bcmh.build/basecamp/assets/flag-gb.svg"/><br/>
@thisislawatts
thisislawatts / acfphp2json.php
Last active June 8, 2017 20:25
Convert ACF php files to ACFJSON
<?php
function convert_ACF_PHP_2_Json() {
$status = [];
$theme_dir = get_stylesheet_directory();
$json_output_dir = $theme_dir . '/acf-json/';
if (!file_exists($json_output_dir)) {
die('Create a acf-json/ directory in your current theme.');
php %home%\site\wwwroot\artisan schedule:run
@thisislawatts
thisislawatts / blog.json
Last active November 8, 2016 14:37
Blimp Blog JSON Output
{
"posts" : [
{
"date" : "",
"title" : "",
"media" : [{}],
"link" : "",
"size" : 1
}
]
<!-- HEADER -->
<script>
trekkie.load(
{"Trekkie":{"appName":"storefront","environment":"production","defaultAttributes":{"shopId":484002}},"Performance":{"navigationTimingApiMeasurementsEnabled":true,"navigationTimingApiMeasurementsSampleRate":0.001},"Google Analytics":{"trackingId":"UA-16504055-1","domain":"auto","siteSpeedSampleRate":"10","enhancedEcommerce":true,"doubleClick":true,"includeSearch":true}}
);
</script>
<!-- FOOTER -->
<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
@thisislawatts
thisislawatts / tidy.php
Last active March 28, 2017 07:24
Single file tidy up for WordPress
<?php
/**
* WordPress tidy up
*
*/
remove_action( 'wp_head', 'feed_links', 2 );
remove_action( 'wp_head', 'feed_links_extra', 3 );
@thisislawatts
thisislawatts / .htaccess
Created February 23, 2016 10:56
WordPress .htaccess
# ----------------------------------------------------------------------
# | Server software information |
# ----------------------------------------------------------------------
# Prevent Apache from adding a trailing footer line containing
# information about the server to the server-generated documents
# (e.g.: error messages, directory listings, etc.)
#
# https://httpd.apache.org/docs/current/mod/core.html#serversignature