Skip to content

Instantly share code, notes, and snippets.

View quotebacks-bookmarklet.js
javascript: (function() {
function removeEmpty(elem) {
var children = elem.children;
for (var i = 0; i < children.length; i++) {
if (children[i].textContent.trim() === '' && children[i].innerHTML.trim().length === 0) children[i].parentNode.removeChild(children[i]);
}
return elem;
}
function convertAbsolute(url) {
View fragmentlink.js
View client-outliner-template
- Admin
- Client contact:
- Project start date:
- Fee:
- **Project Thesis**
- Thesis statement
- #todo
- Task 1
- Meeting Notes
- [[June 1st, 2020]] - Met with Person A, Person B
View book-urlnotes.json
{
"title": "Tempo - timing, tactics and strategy in narrative-driven decision-making",
"id": null,
"author": "Venkatesh Rao",
"link": "https://www.amazon.com/Tempo-tactics-strategy-narrative-driven-decision-making-ebook/dp/B0069CHSLW",
"image": null,
"date_finished": "09/09/19",
"notes": [
"https://tomcritchlow.com/2020/04/13/tempo-notes-chapter-2/",
"https://tomcritchlow.com/2020/04/13/tempo-notes-chapter-1/"
@tomcritchlow
tomcritchlow / thread-embedder.js
Last active Apr 1, 2020
A bookmarklet to grab the URLs in a tweet thread and copy all the embed code to the clipboard
View thread-embedder.js
javascript: (function() {
var username = document.location.href.split("/")[3];
var urls = document.querySelectorAll("a");
var tweets = "<blockquote class='twitter-tweet' data-conversation='none'><a href='https://twitter.com"+document.location.href+"'></a></blockquote><script async src='https://platform.twitter.com/widgets.js' charset='utf-8'></script>\n\n";;
var count = 1;
urls.forEach(myFunction);
function myFunction(item, index) {
if(item.getAttribute("href").includes(username+"/status/") && !(item.getAttribute("href").includes("/retweets")) && !(item.getAttribute("href").includes("/likes"))){
View sidenote.txt
I like this idea - that the most useful thing you need client input and co-creation on is the “base reality” - the “Who, What, Where”. For consultants coming in from the outside attempting to “solve problems” for clients the biggest flaw in generic strategies is not properly accounting for who is at the company, what we’re actually trying to solve and where this strategy will play out{% include tufte-sn.html id="just" content="Recall from <a href='https://tomcritchlow.com/2019/11/19/optimism-operating-system/'>chapter 2</a> - there is no 'just' in consulting - clients are ecosystems in balance..." %}.
@tomcritchlow
tomcritchlow / quote-text.js
Created Jun 19, 2019
A bookmarklet for turning selected text into a quote for markdown blogs
View quote-text.js
function getSelectionText() {
var text = "";
if (window.getSelection) {
text = window.getSelection().toString();
} else if (document.selection && document.selection.type != "Control") {
text = document.selection.createRange().text;
}
return text;
}
@tomcritchlow
tomcritchlow / annotations.gs
Last active May 23, 2019
annotation-tracker-google-scripts
View annotations.gs
function myFunction() {
var ss = SpreadsheetApp.getActiveSpreadsheet();
var outputsheet = ss.getSheets()[0];
// get the existing IDs already in our spreadsheet in column A, sheet 1
var existingfeeddata = outputsheet.getRange("A:A").getValues();
var ids = [];
for(var i in existingfeeddata){
ids.push(existingfeeddata[i][0]); // convert 2d getvalues array to 1d array of IDs
}
@tomcritchlow
tomcritchlow / hypothesis-gist.js
Last active Jun 29, 2020
Current customization for hypothesis annotation layer. See post here: https://tomcritchlow.com/2019/02/12/annotations/
View hypothesis-gist.js
<script type="application/json" class="js-hypothesis-config">
{
"openSidebar": false,
"theme": "clean"
}
</script>
<script src="https://hypothes.is/embed.js" async></script>
<script type="text/javascript">
View mathematical-shapes-rnn.txt
hemioctahedron
Parabier won fle
Spiral
Hitesore curvet
Pentahedron
Great Lcetux
Trocor plian stat
drapnage pysshedtiptated of Var1
Lecthoctahedra
Cincagon
You can’t perform that action at this time.