Skip to content

Instantly share code, notes, and snippets.

View nickbouton's full-sized avatar
💣
word to ya mom, I came to drop bombs

Nick Bouton nickbouton

💣
word to ya mom, I came to drop bombs
View GitHub Profile
@adrianhajdin
adrianhajdin / card.html
Created February 21, 2025 13:20
Tailwind CSS Dark Mode Card
<div class="m-10 rounded-lg bg-white px-6 py-8 shadow-xl ring-1 ring-slate-900/5 dark:bg-black">
<h3 class="text-base font-medium tracking-tight text-slate-900 dark:text-white">Writes Upside-Down</h3>
<p class="mt-2 text-sm text-slate-500 dark:text-blue-100">The Zero Gravity Pen can be used to write in any orientation, including upside-down. It even works in outer space.</p>
<button
id="toggleDark"
class="px-4 py-2 text-sm font-medium mt-8 text-blue-900 bg-blue-100 rounded-md"
onclick="document.body.classList.toggle('dark')"
>Toggle Dark Mode</button>
</div>
@ruvnet
ruvnet / setup.py
Created January 23, 2025 17:45
update sparc setup.py
from setuptools import setup, find_packages
from pathlib import Path
# Read the contents of README.md
this_directory = Path(__file__).parent
long_description = (this_directory / "README.md").read_text()
setup(
name='sparc',
version='0.87.6',
packages=['sparc_cli'] + ['sparc_cli.' + pkg for pkg in find_packages('sparc_cli')],
package_dir={'sparc_cli': 'sparc_cli'},
@borekb
borekb / README.md
Last active September 15, 2025 09:48
How to link to headings in GitHub issues and pull requests

How to link to headings in GitHub issues and pull requests

If you have an issue comment / PR description on GitHub, it doesn't automatically get anchors / IDs that you could link to:

Screenshot 2019-07-11 at 13

What I like to do is to add a visible # character like this:

Screenshot 2019-07-11 at 13 42 21

@stefanneculai
stefanneculai / index.html
Created November 9, 2018 13:08
Froala Editor with Webpack 4
<!doctype html>
<html>
<head>
<title>Froala with Webpack</title>
</head>
<body>
<div id="editor"></div>
@remarkablemark
remarkablemark / README.md
Last active May 23, 2024 20:32
How to mock `window.location.reload` in Jest and jsdom: https://remarkablemark.org/blog/2018/11/17/mock-window-location/
@gricard
gricard / webpack4upgrade.md
Last active April 20, 2025 23:06
Just some notes about my attempt to upgrade to webpack 4

If you enjoyed reading this, I'm intending to do more blogging like this over here: https://cdgd.tech

This is not a complaint about Webpack or v4 in any way. This is just a record of my process trying it out so I could provide feedback to the webpack team

Hmm... I don't see any docs for 4.0 on https://webpack.js.org. I guess I'll just wing it. All I need to do is npm i -D webpack@next, right?

+ webpack@4.0.0-beta.2
@robertgonzales
robertgonzales / Frame.js
Created December 12, 2017 03:03
Use React portals to render inside shadow dom and iframes
class Frame extends Component {
componentDidMount() {
this.iframeHead = this.node.contentDocument.head
this.iframeRoot = this.node.contentDocument.body
this.forceUpdate()
}
render() {
const { children, head, ...rest } = this.props
return (
@ianmcnally
ianmcnally / lazy-image.js
Last active February 25, 2025 06:10
Lazy image loading
//@flow
import React, { Component } from 'react'
import type { ElementRef } from 'react'
type Props = { src: string, alt: string }
type State = { source?: string }
export default class LazyImage extends Component<Props, State> {
state = {}
@480
480 / gist:3b41f449686a089f34edb45d00672f28
Last active December 2, 2025 17:57
MacOS X + oh my zsh + powerline fonts + visual studio code terminal settings

MacOS X + oh my zsh + powerline fonts + visual studio code (vscode) terminal settings

Thank you everybody, Your comments makes it better

Install oh my zsh

http://ohmyz.sh/

sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
@morewry
morewry / monorepo-tool-comparison.md
Last active May 11, 2022 08:54
Comparison of Monorepo Tools For Web Client / Front End Projects (That Probably Use HTML, CSS, and JS)

Mono Repository Tool Comparison

For Web Client / Front End Projects

(That Probably Use HTML, CSS, and JS)

I made a list of 20 things I might want out of a monorepo tool for a Design System to use as a basis for comparing some of the options including Lerna, Northbrook, and Rush.

⚠️ Northbrook's author says the project is pretty dead and now uses Lerna.

Qualifications Wanted