Installing mysql2
gem errors on Apple silicon M1, M2 or M3 Mac running macOS Sonoma.
Make sure mysql-client
, openssl
and zstd
are installed on Mac via Homebrew.
Replace
mysql-client
with whichever mysql package you are using
# official docs: https://graphql-ruby.org/dataloader/sources.html | |
# app/graphql/sources/association.rb | |
class Sources::Association < ::GraphQL::Dataloader::Source | |
def initialize(association_name, scope = nil) | |
@association_name = association_name | |
@scope = scope | |
end | |
def fetch(records) |
[package] | |
name = "rust_crawler" | |
version = "0.1.0" | |
authors = ["Roland Szabo <rolisz@gmail.com>"] | |
edition = "2018" | |
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html | |
[dependencies] | |
reqwest = { version = "0.10", features = ["json", "blocking"] } |
|
define(function(require) { | |
var React = require('react'); | |
var paramRegex = /__(\d)+/; | |
var parser = new DOMParser(); | |
var errorDoc = parser.parseFromString('INVALID', 'text/xml'); | |
var errorNs = errorDoc.getElementsByTagName("parsererror")[0].namespaceURI; | |
// turns the array of string parts into a DOM | |
// throws if the result is an invalid XML document. |
NOTE: This post now lives (and kept up to date) on my blog: http://hakunin.com/rails3-load-paths
Do nothing. All files in this dir are eager loaded in production and lazy loaded in development by default.
#!/usr/bin/env ruby | |
require 'faraday' | |
require 'em-synchrony' | |
require 'em-synchrony/em-http' | |
require 'em-synchrony/fiber_iterator' | |
conn = Faraday::Connection.new(:url => 'http://localhost:5000') do |builder| | |
builder.use Faraday::Adapter::EMSynchrony # make http request with eventmachine and synchrony | |
end |
/* | |
This overlay provides a 'liquid' mode to the excellent CodeMirror editor (http://codemirror.net/). | |
Add something like this to your CSS: | |
.cm-liquid-tag { | |
color: #32273f; | |
background: #ead9ff; | |
} | |
.cm-liquid-variable { |