This file contains 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
function postDailyOOOEventsToSlack() { | |
// The alphanumeric portion of your Google calendar ID | |
const calendarId = ''; | |
const fullCalendarId = `${calendarId}@group.calendar.google.com`; | |
// The link to your Slack app with an Incoming Webhook | |
const slackWebhookUrl = ''; | |
// Update this URL with your expected timezone | |
const calendarUrl = `https://calendar.google.com/calendar/embed?src=${calendarId}%40group.calendar.google.com&ctz=America%2FLos_Angeles/event`; | |
const today = new Date(); |
This file contains 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
/** TODO: | |
* - Add shortcut acronyms to each prefix | |
* - Remove empty div and return placeholders from component snippets | |
* - Add prop-types to all new file components | |
*/ | |
{ | |
// Component snippets | |
"New Class Component": { | |
"prefix": "new class component", | |
"body": [ |
This file contains 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
UIGraphicsBeginImageContextWithOptions(CGSize(width: 200, height: 200), false, 0.0) | |
let context = UIGraphicsGetCurrentContext() | |
let rectPath = UIBezierPath(roundedRect: CGRectMake(0, 0, 200, 200), cornerRadius: 10) | |
var cutoutPath = UIBezierPath(roundedRect: CGRectMake(30, 30, 140, 140), cornerRadius: 10) | |
rectPath.appendPath(cutoutPath.bezierPathByReversingPath()) | |
UIColor.orangeColor().set() | |
outerForegroundPath.fill() |
This file contains 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
- (void)drawText:(NSString *)textToDraw inFrame:(CGRect)frameRect withFont:(UIFont *)originalFont textColor:(UIColor *)textColor alignment:(PDFTextAlignment)alignment verticalAlignment:(PDFTextVerticalAlignment)verticalAlignment { | |
if (!textToDraw) { | |
// If nil, give it an empty value to draw | |
textToDraw = @""; | |
} | |
// Prepare font | |
CTFontRef font = [self ctFontRefFromUIFont:originalFont]; |
This file contains 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
<meta name="viewport" content="width=1000px; user-scalable=0;" /> |