This is a Ghost "App" that will implement a custom Handlebars helper the same as https://apatchofcode.com/adding-custom-handlebars-for-ghost-equals-awesome/
Create a new directory in contents/apps
eg:
mkdir contents/apps/myhelpers
.table-list-triage { | |
display: none; | |
} | |
.triage-mode .table-list-non-triage, .triage-mode .table-list-filters { | |
display: none; | |
} | |
.boxed-group-list>li.approved .btn-sm, .boxed-group-list>li.rejected .btn-sm { | |
display: none; | |
} | |
.repo-list .participation-graph.disabled { |
javascript:(function(){var styles = document.querySelectorAll('link[rel=\'stylesheet\']'); for (var s = 0; s < styles.length; s++) {styles[s].mediax = styles[s].media;if (styles[s].media === 'only x') { styles[s].media = styles[s].mediax; } else if (styles[s].media !== 'print') {styles[s].media = 'only x';}}})(); |
const I = x => x | |
const K = x => y => x | |
const A = f => x => f (x) | |
const T = x => f => f (x) | |
const W = f => x => f (x) (x) | |
const C = f => y => x => f (x) (y) | |
const B = f => g => x => f (g (x)) | |
const S = f => g => x => f (x) (g (x)) | |
const S_ = f => g => x => f (g (x)) (x) | |
const S2 = f => g => h => x => f (g (x)) (h (x)) |
This is a Ghost "App" that will implement a custom Handlebars helper the same as https://apatchofcode.com/adding-custom-handlebars-for-ghost-equals-awesome/
Create a new directory in contents/apps
eg:
mkdir contents/apps/myhelpers
https://twitter.com/snookca/status/1073299331262889984?s=21
Happy to chat about this. There’s an obvious disclaimer that there’s a cost to css-in-js solutions, but that cost is paid specifically for the benefits it brings; as such it’s useful for some usecases, and not meant as a replacement for all workflows.
(These conversations always get heated on twitter, so please believe that I’m here to converse, not to convince. In return, I promise to listen to you too and change my opinions; I’ve had mad respect for you for years and would consider your feedback a gift. Also, some of the stuff I’m writing might seem obvious to you; I’m not trying to tell you if all people of some of the details, but it might be useful to someone else who bumps into this who doesn’t have context)
So the big deal about css-in-js (cij) is selectors.
// | |
// CAMediaTimingFunction.swift | |
import UIKit | |
extension CAMediaTimingFunction { | |
static let linear = CAMediaTimingFunction(name: .linear) | |
static let easeOut = CAMediaTimingFunction(name: .easeOut) |
type PromiseFactory = () => Promise<any>; | |
function promiseAllBatched( | |
promiseFactories: PromiseFactory[], | |
batchSize: number | |
): Promise<any> { | |
let completed = 0; | |
let upNext = 0; | |
let results: any[] = []; | |
const initialBatchSize = Math.min(batchSize, promiseFactories.length); |
function useCachedAbortiveQuery<T>( | |
query: DocumentNode, | |
variables: Record<string, unknown>, | |
deps: Array<any> | |
) { | |
const apolloClient = useApolloClient(); | |
const [data, setData] = useState<T>(); | |
const [error, setError] = useState<Error | null>(null); | |
const [loading, setLoading] = useState<boolean>(true); |