This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* A function that takes an array of HTML attribute | |
* key/value pairs and returns a string of HTML attributes. | |
**/ | |
function unwrap_html_attrs($attrs) | |
{ | |
$attributes = ''; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build and Publish Production Plugin | |
on: | |
push: | |
branches: [master] | |
jobs: | |
build: | |
runs-on: ubuntu-latest |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$args = wp_parse_args( | |
$args, | |
array( | |
'button' => get_field('button') | |
) | |
); | |
if ($args['button]): ?> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Returns a specified ACF field from a parent block | |
* @param string $child_id The ID of the child ACF block | |
* @param string $child_name The name of the child ACF block | |
* @param string $parent_name The name of the parent ACF block | |
* @param string $field The name of the parent's custom field to return | |
* @param boolean $return_first If $field is an array, optionally return the first item. | |
*/ | |
function get_field_from_parent($child_id, $child_name, $parent_name, $field, $return_first = false) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// webpack.mix.js test | |
let mix = require('laravel-mix'); | |
let tailwindcss = require('tailwindcss'); | |
mix.setPublicPath('assets/dist'); | |
mix.js('assets/src/js/main.js', "assets/dist/js/main.min.js").version(); | |
mix.sass("assets/src/scss/theme.scss", "assets/dist/css/theme.min.css").options({ | |
postCss: [ tailwindcss('./tailwind.config.js') ], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "your_name", | |
"version": "1.2.0", | |
"description": "Your Description", | |
"main": "webpack.mix.js", | |
"devDependencies": { | |
"@tailwindcss/custom-forms": "^0.2.1", | |
"@tailwindcss/forms": "^0.3.2", | |
"@tailwindcss/typography": "^0.4.0", | |
"ajv": "^6.12.6", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$category = get_field('category'); | |
// query arguments | |
$args = array( | |
'category__in' => $category->term_id; | |
'post_status' => 'publish', | |
'posts_per_page' => 10, | |
'orderby' => 'date', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
id: '581', | |
'$uid': '73e7c58f8dcaf08275e9ede885e170e0', | |
internal: { typeName: 'WordPressPost', | |
origin: undefined, | |
mimeType: undefined, | |
content: undefined, | |
timestamp: 1595134058463 | |
}, | |
date: '2020-07-08T18: 58: 21', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Redirect 301 "/spring-trends" "/baby-easter-outfits" | |
Redirect 301 "/safe-baby-sunscreen" "/baby-sunscreen" | |
Redirect 301 "/finding-a-pediatrician" "/find-a-pediatrician" | |
Redirect 410 "/royal-baby" | |
Redirect 410 "/dream-on-me-crib-collapse" | |
Redirect 410 "/recalled-playtex-infant-carrier" | |
Redirect 410 "/ikea-lamps-recalled-for-death" | |
Redirect 301 "/baby-photo-props" "/newborn-photo-props" | |
Redirect 301 "/category/incredible-infants/helpful-gadgets" "/category/incredible-infants/clothes-things" | |
Redirect 410 "/fall-fashion-mom-and-baby-2014" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"key": "group_5be5a1136a415", | |
"title": "Block: Hero", | |
"fields": [ | |
{ | |
"key": "field_5e0afdc64f5a3", | |
"label": "Content", | |
"name": "", | |
"type": "tab", |
NewerOlder