Skip to content

Instantly share code, notes, and snippets.

View aquaductape's full-sized avatar
🐢
🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢

Caleb Taylor aquaductape

🐢
🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢🐢
View GitHub Profile
@aquaductape
aquaductape / custom-emmet-snippet.md
Created November 10, 2023 06:44
Custom Emmet snippets
@aquaductape
aquaductape / my_tailwindconfig.js
Last active March 28, 2024 02:03
A bunch of utilities that I use on every personal tailwind project
plugins: [
plugin(
function ({ addComponents, matchUtilities, theme }) {
matchUtilities(
{
"box-shadow": (value) => ({
boxShadow: value.replace("_", " "),
}),
"text-shadow": (value) => ({
textShadow: value.replace("_", " "),
@aquaductape
aquaductape / solid.txt
Created October 10, 2023 22:49
solidjs stuff
https://playground.solidjs.com/anonymous/381683f7-5b1b-48e0-b3ca-b4373ef60fff
@aquaductape
aquaductape / returning.sql
Created August 26, 2023 18:05
One of the ways to return value from insert statement
INSERT INTO cats (name, owner_name, age) VALUES ('aaa', 'joooooohn', 5) RETURNING *;
@aquaductape
aquaductape / hasSolidJS.js
Last active May 10, 2024 00:29
detect solidjs on page
const hasSolidJS = async () => {
if (
typeof window._$HY === "object" &&
window._$HY.completed instanceof WeakSet
)
return true;
const hydrateKeyName = "data-hk";
const bodyFirstEl = document.body.firstElementChild;
@aquaductape
aquaductape / ruby_rails_timestamp.rb
Last active August 22, 2023 22:49
how to get produce timestamp like rails
# how to get produce timestamp like rails
#
# ActiveRecord::Schema[7.0].define(version: 2023_03_19_164906) do
# create_table "articles", force: :cascade do |t|
# t.datetime "created_at", null: false
# t.datetime "updated_at", null: false
# end
# end
# `%6N` is microsecond ( 6 digits )
@aquaductape
aquaductape / documenting-best-raster-to-svg-converter.svg
Created October 16, 2022 03:19
Documenting the best Raster to SVG converter [Inkscape SVG File]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
function namespaceSVGId(svg, namespace) {
svg = svg.replace(/id="(.*?)"/g, (_, p1) => {
return `id="${namespace}-${p1}"`;
});
svg = svg.replace(/xlink:href="#(.*?)"/g, (_, p1) => {
return `xlink:href="#${namespace}-${p1}"`;
});
svg = svg.replace(/mask="url\(#(.*?)\)"/g, (_, p1) => {
return `mask="url(#${namespace}-${p1})"`;
@aquaductape
aquaductape / Madness.sh
Created June 14, 2020 04:41
Need for Madness installation file for Linux
#!/usr/bin/env bash
PWD=`pwd`
ZULU_URL='https://cdn.azul.com/zulu/bin/zulu7.38.0.11-ca-jdk7.0.262-linux_x64.tar.gz'
ZULU='zulu-jdk7'
ZULU_ARCHIVE="/opt/${ZULU}.tar.gz"
USER_DATA="${PWD}/data/user.data"
JAVA7="/opt/${ZULU}/bin/java"
@aquaductape
aquaductape / isObject.js
Created May 22, 2020 20:06
exercise to check if input is object without using Equality operators or Object.is()
// exercise to check if input is object without using
// Equality operators or Object.is()
const isObject = (input) => {
/******* Easiest Way ********/
if (!input) return false;
return !!(typeof input).match(/object|function/);
/******* Longer Solution ********/