See how a minor change to your commit message style can make you a better programmer.
Format: <type>(<scope>): <subject>
<scope>
is optional
<div x-data="{ open: false, filter: '', selected: <%= @options.select { |option| @form.object.send(@field).any?(option[1]) } %>, options: <%= @options %> }" class="flex flex-col"> | |
<div class="flex flex-row justify-between"> | |
<label for="<%= @field %>"> | |
<%= @label %> | |
</label> | |
<button type="button" class="link text-sm" @click="selected = []"> | |
Clear <%= @label.downcase %> | |
</button> | |
</div> |
# frozen_string_literal: true | |
require 'uri' | |
require 'net/http' | |
require 'openssl' | |
require 'json' | |
class EasyBrokerApi | |
BASE_URL = 'https://api.stagingeb.com/v1' |
/* Using a JavaScript proxy for a super low code REST client */ | |
// via https://dev.to/dipsaus9/javascript-lets-create-aproxy-19hg | |
// also see https://towardsdatascience.com/why-to-use-javascript-proxy-5cdc69d943e3 | |
const createApi = (url) => { | |
return new Proxy({}, { | |
get(target, key) { | |
return async function(id = "") { | |
const response = await fetch(`${url}/${key}/${id}`) | |
if (response.ok) { | |
return response.json(); |
How to get auto-deploy working from Gitlab to your Digital Ocean (DO) server.
Install https://github.com/olipo186/Git-Auto-Deploy (via apt-get):
sudo apt-get install software-properties-common
sudo add-apt-repository ppa:olipo186/git-auto-deploy
sudo apt-get update
sudo apt-get install git-auto-deploy