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
| <role> | |
| You are a principal software engineer. Measure twice, cut once. | |
| </role> | |
| <rules> | |
| - Do NOT generate or modify code until analysis and planning are complete. | |
| - If any requirement is ambiguous, ask one focused question rather than assuming or asking many. | |
| - Prioritize maintainability and readability over cleverness or speed. | |
| - Do NOT touch code outside the scope of the request. | |
| - Preserve existing patterns and conventions unless there is a clear reason to deviate. |
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
| // Word lists | |
| const nounsOpenSource = [ | |
| 'Fork', 'Commit', 'Patch', 'Module', 'Branch', 'Merge', 'Token', 'Kernel', 'Repo', 'Hook' | |
| ]; | |
| const nounsWordPress = [ | |
| 'Plugin', 'Theme', 'Block', 'Template', 'Dashboard', 'Widget', 'Post', 'Page', 'Core', 'Loop' | |
| ]; | |
| const nounsHeadless = [ |
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
| <iframe id="wp-playground" style="width: 100%; height: 100%" frameBorder="0"></iframe> | |
| <script type="module"> | |
| import { | |
| startPlaygroundWeb | |
| } from 'https://unpkg.com/@wp-playground/client/index.js'; | |
| const client = await startPlaygroundWeb({ | |
| iframe: document.getElementById('wp-playground'), | |
| remoteUrl: `https://playground.wordpress.net/remote.html`, | |
| blueprint: { | |
| landingPage: '/wp-admin/options-general.php?page=faustwp-settings', |
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
| import React from 'react'; | |
| import { FaustHooks, FaustPlugin } from '@faustwp/core'; | |
| import { FaustToolbarNodes, ToolbarNodeSkeleton } from '@faustwp/core/toolbar'; | |
| export class CustomToolbar implements FaustPlugin { | |
| apply(hooks: FaustHooks) { | |
| hooks.addFilter('toolbarNodes', 'faust', (toolbarNodes: FaustToolbarNodes) => { | |
| const customToolbarNodes: FaustToolbarNodes = [ | |
| { |
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
| #!/usr/bin/env bash | |
| # Exit if WP-CLI is not available. | |
| if ! command -v wp &> /dev/null | |
| then | |
| echo "This script requires WP-CLI" | |
| exit | |
| fi | |
| # Install WordPress plugins. |
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
| .container { | |
| width: (10/12) * 100%; | |
| } | |
| .container { | |
| width: percentage(10/12); | |
| } |
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
| // My existing WordPress Project that requires MDL | |
| // Assign namespace above MDL base-ui scss import. | |
| // If no $namespace is assigned before importing MDL base-ui, | |
| // no namespace is added. | |
| $namespace: '#project-defined .specificity'; | |
| // Import single MDL scss file from within node_modules (Mimmick MDL import) | |
| // @import "~@masonite/base-ui/styles/style.scss"; |
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
| .rating { | |
| &__bar { | |
| // Generate our rating__bar data selectors. | |
| @for $i from 0 through 10 { | |
| &[data-value="#{$i}"] { | |
| &:before{ | |
| width: $i * 10%; | |
| } | |
| &:after{ | |
| left: $i * 10%; |
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 | |
| /* | |
| Valet driver for Wordpress Multisite | |
| Usage: Drop this file into your ~/.valet/Drivers/ directory | |
| */ | |
| class WordPressMultisiteValetDriver extends WordPressValetDriver | |
| { | |
| /** |
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
| <!-- Keep unnecessary dev stuff out of backup --> | |
| <excludefname_rule plat="mac" osVers="*" ruleIsOptional="t" skipFirstCharThenStartsWith="users/" contains_1="/.git/" doesNotContain="*" endsWith="*" hasFileExtension="*" /> | |
| <excludefname_rule plat="mac" osVers="*" ruleIsOptional="t" skipFirstCharThenStartsWith="users/" contains_1="/.svn/" doesNotContain="*" endsWith="*" hasFileExtension="*" /> | |
| <excludefname_rule plat="mac" osVers="*" ruleIsOptional="t" skipFirstCharThenStartsWith="users/" contains_1="/vendor/" doesNotContain="*" endsWith="*" hasFileExtension="*" /> | |
| <excludefname_rule plat="mac" osVers="*" ruleIsOptional="t" skipFirstCharThenStartsWith="users/" contains_1="/bower_components/" doesNotContain="*" endsWith="*" hasFileExtension="*" /> | |
| <excludefname_rule plat="mac" osVers="*" ruleIsOptional="t" skipFirstCharThenStartsWith="users/" contains_1="/node_modules/" doesNotContain="*" endsWith="*" hasFileExtension="*" /> |
NewerOlder