Suggest sites to user based on URL matching and other information. Might require crawling the site or calling out to a search API like Duck Duck Go.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| # start — tmux dev session manager | |
| # Creates a split-pane dev layout: claude | shell / git-status watch | |
| # Pure Bash version (no dependencies beyond tmux + fzf) | |
| set -euo pipefail | |
| # ── Helpers ────────────────────────────────────────────────────────────────── | |
| sanitize_session_name() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # just the basics (friendly, nonconfrontational) | |
| defaults write com.apple.dock persistent-apps -array && \ | |
| defaults write com.apple.dock persistent-others -array && \ | |
| killall Dock; | |
| # how I like it (wired, wild) | |
| defaults write com.apple.dock persistent-apps -array && \ | |
| defaults write com.apple.dock persistent-others -array && \ | |
| defaults write com.apple.dock autohide -bool true && \ | |
| defaults write com.apple.dock magnification -bool true && \ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| yarn-path "./yarn-1.12.3.js" |
Snapshots can be helpful, but if used improperly they can useless or even a burden.
Don't snapshot things you don't care about. Don't snapshot an entire wrapper component if you are only interested in a single subcomponent. You can use enzyme's find() (available on both shallow and full wrappers).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| converts an array of objects into an array of row arrays, | |
| suitable for use in e.g. a csv coversion (npm install csv-stringify) | |
| includes the header row. | |
| e.g. | |
| objectArray = [{a: 1, b: 120}, {a: 2, c: 'horse'}] | |
| toRows(objectArray) -> [ ['a', 'b', 'c'], [1, 120, undefined], [2, undefined, 'horse'] ] | |
| */ | |
| const toRows = objectArray => { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // quick and dirty populating ("joining") in Meteor | |
| Mongo.Collection.prototype.findAndPopulate = function (selector, options, populates) { | |
| /* | |
| selector and options: from Mongo.Collection.prototype.find(selector, options) | |
| populates: [Object] or Object | |
| [{id, as, from}] or {id, as, from} | |
| e.g. {id: 'userId', as: 'thisUser', from: Users} | |
| will look up doc.userId in Users and assign to doc.thisUser | |
| --> doc.thisUser = Users.findOne(doc.userId); | |
| */ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html > | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"/> | |
| <title>chris bolin 2</title> | |
| <link rel="stylesheet" href="css/normalize.css"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var repl = require('repl'), | |
| keystone = require('keystone'); | |
| module.exports = function(done) { | |
| var shell = repl.start({ | |
| prompt: 'keystone > ' | |
| }); | |
| // expose keystone to the shell | |
| shell.context.keystone = keystone; |
NewerOlder