Open app/setup.php
, find the after_setup_theme
action and put add_theme_support('woocommerce');
inside the function.
Add the templates you want to override in resources/woocommerce
:
theme
│
root() { | |
local root | |
if [[ "$PWD" == *"/trellis"* ]]; then | |
root=${PWD%/trellis*} | |
elif [[ "$PWD" == *"/site"* ]]; then | |
root=${PWD%/site*} | |
elif [[ -d "$PWD/trellis" || -d "$PWD/site" ]]; then | |
root=${PWD} | |
fi |
static propertyControls: PropertyControls = { | |
text: { type: ControlType.String, title: 'Text' }, | |
fontSize: { | |
type: ControlType.FusedNumber, | |
toggleKey: 'fontPerBP', | |
toggleTitles: ['Font', 'Font per BP'], | |
valueKeys: ['font1', 'font2', 'font3', 'font4'], | |
valueLabels: theme.breakpoints.map(s => s.replace('px', '')), | |
min: 0, | |
title: 'Font Size', |
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<title></title> | |
</head> | |
<body> | |
<script> | |
// Test if service workers are supported | |
if ('serviceWorker' in navigator) { |
<?php | |
/** | |
* Plugin Name: WP REST API Strict Mode | |
* Description: Triggers an error when unregistered parameters are used. | |
* Author: Ryan McCue | |
* Author URI: http://rmccue.io/ | |
* Version: 0.1 | |
* | |
* Requires https://core.trac.wordpress.org/ticket/35507 | |
*/ |
/** | |
* Used to clone and apply props to children | |
*/ | |
function cloneChildren(children, callback) { | |
const childrenArray = React.Children.toArray(children).filter( | |
child => child !== undefined && child !== null && child !== false | |
) | |
const childrenCount = childrenArray.length | |
return childrenArray.map( | |
(child, index) => |
// If the user has been on the page for over 12 hours, the next link | |
// click will do a full page transition to get new code | |
import React from "react"; | |
import { BrowserRouter, useLocation } from "react-router-dom"; | |
let hour = 3600000; | |
export default function StaleAppRouter(props) { | |
let [isStale, setIsStale] = useState(false); |
<?php | |
declare( strict_types=1 ); | |
$wp_dir = '/application/www/wp/'; | |
$preload_patterns = [ | |
$wp_dir . "wp-includes/Text/Diff/Renderer.php", | |
$wp_dir . "wp-includes/Text/Diff/Renderer/inline.php", | |
$wp_dir . "wp-includes/SimplePie/**/*.php", | |
$wp_dir . "wp-includes/SimplePie/*.php", |
background #e8e9ec | |
foreground #33374c | |
selection_background #d2d4dd | |
selection_foreground #33374c | |
cursor #33374c | |
cursor_text_color #e8e9ec | |
# white |
--- | |
- name: Sync uploads between environments | |
hosts: web | |
remote_user: "{{ web_user }}" | |
vars: | |
project: "{{ wordpress_sites[site] }}" | |
project_root: "{{ www_root }}/{{ site }}" | |
tasks: |