By: @BTroncone
Also check out my lesson @ngrx/store in 10 minutes on egghead.io!
Update: Non-middleware examples have been updated to ngrx/store v2. More coming soon!
Table of Contents
| # coding: utf-8 | |
| import json | |
| import stripe | |
| import datetime | |
| # Required for OAuth flow | |
| from rauth import OAuth2Service | |
| # Our secret key from stripe | |
| STRIPE_SECRET_KEY = 'sk_test_xxxxxxxxxxxxx' |
| <?php | |
| /* | |
| * Allows manual override on a per page/post basis | |
| * for the display of the Roots Sidebar | |
| * | |
| * Allows for filtering the post types that show the metabox | |
| * | |
| */ |
| class App extends React.Component { | |
| constructor(props) { | |
| this.state = { | |
| count: 0 | |
| } | |
| } | |
| onClick(e) { | |
| this.setState({ | |
| count: this.state.count + 1 |
By: @BTroncone
Also check out my lesson @ngrx/store in 10 minutes on egghead.io!
Update: Non-middleware examples have been updated to ngrx/store v2. More coming soon!
Table of Contents
| <?php | |
| /** | |
| * @package Kinsta_widget | |
| * @version 1.0 | |
| */ | |
| /* | |
| Plugin Name: Kinsta Widget | |
| Plugin URI: http://wordpress.org/extend/plugins/# | |
| Description: This is an example plugin | |
| Author: Your Name |
| /** | |
| * Add this to your setup.php | |
| * Usage @loop( $wp_query ) or $loop and end with @endloop | |
| * the new $loop variable is available | |
| */ | |
| /** | |
| * Create @loop Blade directive | |
| */ | |
| sage('blade')->compiler()->directive('loop', function ( $query = null ) { |
| <?php | |
| namespace App; | |
| use Carbon_Fields\Field; | |
| use Carbon_Fields\Block; | |
| Block::make( __( 'Gutenberg Block' ) ) | |
| ->set_icon( 'format-chat') | |
| ->add_fields( array( | |
| Field::make( 'rich_text', 'text', __( 'text', 'my-theme' ) ) |
It's quite straightforward to use GitLab Pages to deploy a Storybook instance per branch (and remove it whenever the branch will be removed). And yeah, it's irony to document this in a GitHub Gist 😅
You just need a .gitlab-ci.yml like this one:
stages:
- setup
- build-and-test
- deployment
- pages