Add an NPM_TOKEN secret on GitHub. Get your secret key from the NPM dashboard.
- name: Authenticate with private NPM package
run: echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" > ~/.npmrc| // Gist for https://medium.com/@ebakhtarov/bidirectional-websockets-with-redux-saga | |
| import { eventChannel } from "redux-saga"; | |
| import { all, call, put, take, select, race } from "redux-saga/effects"; | |
| import { actionTypes } from "./constants"; | |
| function watchMessages(socket) { | |
| return eventChannel(emit => { | |
| /* eslint-disable no-param-reassign */ |
| import { FieldProps } from 'formik' | |
| import React from 'react' | |
| import Select, { Option, ReactSelectProps } from 'react-select' | |
| export const SelectField: React.SFC<ReactSelectProps & FieldProps> = ({ | |
| options, | |
| field, | |
| form, | |
| }) => ( | |
| <Select |
| def create_batch(conn, %{"people" => people_params}) do | |
| changesets = Enum.map(people_params, fn class -> | |
| Person.changeset(%Person{}, person) | |
| end) | |
| result = changesets | |
| |> Enum.with_index() | |
| |> Enum.reduce(Ecto.Multi.new(), fn ({changeset, index}, multi) -> | |
| Ecto.Multi.insert(multi, Integer.to_string(index), changeset) | |
| end) |
| remove_action( 'woocommerce_after_shop_loop_item', 'woocommerce_template_loop_add_to_cart', 10); |
| defmodule MyApp.Schema.ArcResolver do | |
| defmacro __using__([uploader: uploader]) do | |
| quote do | |
| import unquote(__MODULE__), only: [ | |
| get_file: 2 | |
| ] | |
| @__arc_upload unquote(uploader) | |
| end | |
| end |
| import React from 'react' | |
| import { withRouter, Link } from 'react-router-dom' | |
| import { graphql, compose } from 'react-apollo' | |
| import { Formik } from 'formik' | |
| import Yup from 'yup' | |
| import FormWideError from '../elements/form/FormWideError' | |
| import TextInput from '../elements/form/TextInput' | |
| import Button from '../elements/form/Button' | |
| import { H2 } from '../elements/text/Headings' |
| <ul class="products"> | |
| <?php | |
| $args = array( | |
| 'post_type' => 'product', | |
| 'posts_per_page' => 12, | |
| 'tax_query' => array( | |
| array( | |
| 'taxonomy' => 'product_visibility', | |
| 'field' => 'name', | |
| 'terms' => 'featured', |
| if ( ! defined( 'ABSPATH' ) ) { | |
| exit; // Exit if accessed directly | |
| } | |
| get_header( 'shop' ); ?> | |
| <?php | |
| /** | |
| * woocommerce_before_main_content hook. | |
| * |
| defmodule Languafy.Schema do | |
| use Absinthe.Schema | |
| import_types Languafy.Schema.Types | |
| query do | |
| @desc "Get an App User" | |
| field :user, type: :user do | |
| arg :id, non_null(:id) | |
| resolve &Languafy.Resolver.User.find/2 | |
| end |