Skip to content

Instantly share code, notes, and snippets.

View tdak's full-sized avatar
🏠
Working from home

tdak

🏠
Working from home
View GitHub Profile

Rails & Trix: Add Underline, Superscript, and Subscript

This guide will walk you through adding some extra features such as the ability to underline your text, or enhance your content by adding superscripts or subscripts for annotations or Math equations.

Prerequisites: Instruction guide assumes that you have created a Rails application and installed ActionText.

What will you learn:

@tdak
tdak / ajax_frame.js
Last active December 6, 2020 20:47
Turbolinks-Frame implementation for Rails, javascript and A Controller Concern
export class AjaxFrame {
updateAjaxFrame(e_id, load_turbolinks = true) {
var element = document.getElementById(e_id)
if (!element) {
return
}
var url = element.getAttribute("src")
@tdak
tdak / _project.html.erb
Created November 10, 2020 13:24
Reactive Ajax Components for Rails
<div>
<%= project.name %>
</div>
@tdak
tdak / gist:98b4cb252fef4124f8cf79d93ef1bf8d
Created October 21, 2020 22:26
Dokku Trace Dump when it fails
23:27 $ git push dokku_3 master
+ export DOKKU_HOST_ROOT=/home/dokku
+ DOKKU_HOST_ROOT=/home/dokku
+ export DOKKU_DISTRO
++ . /etc/os-release
++ echo ubuntu
+ DOKKU_DISTRO=ubuntu
+ export DOCKER_BIN=docker
+ DOCKER_BIN=docker
+ export DOKKU_IMAGE=gliderlabs/herokuish:latest