Skip to content

Instantly share code, notes, and snippets.

Stefan Crowe stefancrowe

Block or report user

Report or block stefancrowe

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@stefancrowe
stefancrowe / functions.php
Created Jan 17, 2019
WordPress Advanced Custom Fields - Organise Field Groups into categories with sort
View functions.php
/**
* Add support for Field Group categories to Advanced Custom Fields (WordPress plugin).
*
* Drop this code into your theme's functions.php or equivalent file. This will
* then allow you to add categories to Field Groups on the edit screen. It also
* adds a "Category" column to the Field Groups list page - users can click
* on the category name to filter the Field Groups by that category.
*
* @author Stefan Crowe <me@stefancrowe.co.uk>
*/
@stefancrowe
stefancrowe / gulpfile.js
Created Dec 8, 2016
Gulp Task to generate a JSON array of Font Awesome 4.* icons from the package
View gulpfile.js
require('fs');
require('gulp');
/**
* Create JSON array of icons from Font Awesome _icons.scss (based on v4.*).
* Replace PATH_TO_FONT_AWESOME and PATH_TO_SAVE with your relevant paths.
*/
gulp.task('icons', function() {
// Pattern to only match the icon name (excluding "fa-")
var re = /^.\#\{\$fa\-css\-prefix\}\-([a-z0-9\-]*)\:before { content: \$fa\-var\-[a-z0-9\-]*\; }$/gmi;
You can’t perform that action at this time.