This gist will collects all issues we solved with Rails 5.2 and Webpacker
# Last few parameters(--skip-* part) is only my habbit not actully required
$ rails new <project_name> --webpack=stimulus --database=postgresql --skip-coffee --skip-test
public class GetEventStoreRepository : IRepository | |
{ | |
private const string EventClrTypeHeader = "EventClrTypeName"; | |
private const string AggregateClrTypeHeader = "AggregateClrTypeName"; | |
private const string CommitIdHeader = "CommitId"; | |
private const int WritePageSize = 500; | |
private const int ReadPageSize = 500; | |
private readonly Func<Type, Guid, string> _aggregateIdToStreamName; |
public sealed class NServiceBusCommitDispatcher : IPublishMessages | |
{ | |
private const string AggregateIdKey = "AggregateId"; | |
private const string CommitVersionKey = "CommitVersion"; | |
private const string EventVersionKey = "EventVersion"; | |
private const string BusPrefixKey = "Bus."; | |
private readonly IBus bus; | |
public NServiceBusCommitDispatcher(IBus bus) | |
{ |
## This is a sample NXLog configuration file created by Loggly. June 2013 | |
## See the nxlog reference manual about the configuration options. | |
## It should be installed locally and is also available | |
## online at http://nxlog.org/nxlog-docs/en/nxlog-reference-manual.html | |
## Please set the ROOT to the folder your nxlog was installed into, | |
## otherwise it will not start. | |
#define ROOT C:\Program Files\nxlog | |
define ROOT C:\Program Files (x86)\nxlog |
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
namespace Voron.Util | |
{ | |
/// <summary> | |
/// A list that can be used by readers as a true immutable read-only list | |
/// and that supports relatively efficient "append to the end" and "remove | |
/// from the front" operations, by sharing the underlying array whenever |
const Account = require("../models/account") | |
module.exports = (handler) => async (event, context) => { | |
let auth = event.headers.authorization | |
auth = auth.replace(/^Basic\s/, "") | |
auth = Buffer.from(auth, 'base64').toString() | |
const [id, token] = auth.split(":") | |
const account = await Account.get({ id }) |
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Security; | |
using System.Web; | |
using System.Web.Hosting; | |
namespace PdfGenerator | |
{ | |
public class PdfGenerator |
const https = require("https") | |
const fetch = require("isomorphic-fetch") | |
const Account = require("./models/account") | |
const authenticated = require("./lib/auth") | |
exports.handler = authenticated(async (event, context) => { | |
const { id: shopId, shopifyToken } = context.account | |
try { | |
const resp = await fetch(`https://${shopId}/admin/api/2019-07/graphql.json`, { |
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Net; | |
using System.Text; | |
using System.Threading; | |
using EventStore.ClientAPI; | |
namespace marketdata | |
{ |
This gist will collects all issues we solved with Rails 5.2 and Webpacker
# Last few parameters(--skip-* part) is only my habbit not actully required
$ rails new <project_name> --webpack=stimulus --database=postgresql --skip-coffee --skip-test
import * as admin from 'firebase-admin' | |
import * as functions from 'firebase-functions' | |
admin.initializeApp(functions.config().firebase) | |
const db = admin.firestore() | |
async function writeIntegerVersion(event) { | |
const ref = event.data.ref | |
if (ref.path.indexOf('/_versions/') >= 0) { | |
return false |