Workflow, Tips

10 Text-Expander Snippets And Shortcuts I Use With Notion

notion_textexpander_shortcuts-snippets.jpg

🧰 Shortcuts & Snippets

I use TextExpander everyday to boost my productivity. I use it to speed my writing process with a series of shorthand commands (ie. \ven = View Example In Notion). The following are ten snippets I use that are also very useful inside Notion. For those who use Notion and TextExpander this list may offer some inspiration.

Universal Snippets

1. Lowercase (Shell Script)

Turn all text in the clipboard to lowercase.

Shortcut: %lc

#!/usr/bin/perl -w

use strict;

my($text);

$text =`pbpaste`;

print "\L$text";

 

2. Plain Text (Shell Script)

Remove all formatting from text in the clipboard.

Shortcut: %wilk

#!/usr/bin/perl -w

use strict;

my($text);

$text =`pbpaste`;

print $text

 

3. Replace Whitespace (Shell Script)

Replace all whitespace from text in the clipboard with a dash.

Shortcut: \-pl

#!/usr/bin/perl -w

use strict;

my($text);

$text =`pbpaste | sed -e 's/ /-/g'`;

print $text

 

4. Random Number 1-100 (Javascript)

Return a random number between 1 and 100.

Shortcut: %dm

Math.floor(Math.random() * 100) + 1

 

Snippets With Notion

5. Red Superscript (Plain Text)

ezgif.com-gif-maker (19).gif

Return a superscript with red font.

Shortcut: \sp

\color{red}^{FILL-IN} POSITION CURSOR HERE

 

6. Google Maps (Plain Text)

Screen%2BShot%2B2021-02-22%2Bat%2B4.14.36%2BPM.jpg

Return an embed of a specific location with Google Maps.

Shortcut: \gb

https://www.google.com/maps/place/FILL-IN

How ‘Fill-In’ should be arranged: city,+country

 

7. Random Weekday (Javascript)

ezgif.com-gif-maker (18).gif

Return a random weekday from “Monday” to “Sunday.”

Shortcut: \day

var qList = ["monday","tuesday","wednesday","thursday","friday","saturday","sunday"]

var qLength = qList.length

var qRandom = Math.floor((Math.random() * qLength));

qList[qRandom]

 

Various Symbols

8. Between (Plain Text)

Shortcut: ^bet

 

9. Change (Plain Text)

Shortcut: ^cha

 

10. Star Ratings

Screen+Shot+2021-02-22+at+6.34.53+PM.jpg

Returns star ratings in a list from 1-5 using optional selections.

Shortcut: ^rate