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
// Import the core angular services. | |
import { Component } from "@angular/core"; | |
// Import the application components and services. | |
import { TextSelectEvent } from "./text-select.directive"; | |
// ----------------------------------------------------------------------------------- // | |
// ----------------------------------------------------------------------------------- // | |
interface SelectionRectangle { |
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
// Create an instance of our cache and set some keys. Notice that the [new] operator | |
// is optional since the SimpleCache (and revealing module pattern) doesn't use | |
// prototypical inheritance. And, we can use method-chaining to set the cache keys. | |
var cache = SimpleCache() | |
.set( "foo", "Bar" ) | |
.set( "hello", "world" ) | |
.set( "beep", "boop" ) | |
; | |
console.log( cache.has( "beep" ) ); |
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
component { | |
/** | |
* I get called once at the start of each incoming ColdFusion request. | |
*/ | |
public void function onRequestStart() { | |
for ( var key in form ) { | |
if ( isSimpleValue( form[ key ] ) ) { |
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
// Import the core angular services. | |
import { Component } from "@angular/core"; | |
// ----------------------------------------------------------------------------------- // | |
// ----------------------------------------------------------------------------------- // | |
@Component({ | |
selector: "my-app", | |
styleUrls: [ "./app.component.less" ], | |
template: |
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
.* | |
Dockerfile | |
node_modules |
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
<!doctype html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8" /> | |
<title> | |
Rendering Wrapped Text To A Canvas In JavaScript | |
</title> | |
<link rel="stylesheet" type="text/css" href="./main.css" /> | |
</head> | |
<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
// I define the callback function interface for the .map() method. This entire interface | |
// is parameterized with the given Type <T> so that we can facilitate "type argument | |
// inference" in the method signature for .map(). | |
interface TokensMapCallback<T> { | |
( token: string ) : T; | |
} | |
class Tokens { | |
private _tokens: string[]; |
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
/** | |
* Find the amount of auto-increment "space" has been used. This may can help identify | |
* tables that are running out of available ID values. | |
*/ | |
SELECT | |
t.table_name, | |
t.column_name, | |
-- The highest possible ID that can be created with this data-type. | |
t.max_value, | |
-- The last ID created in this table. |
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
import axios from "axios"; | |
import { AxiosInstance } from "axios"; | |
import { ErrorHandler } from "@angular/core"; | |
import { Injectable } from "@angular/core"; | |
// ----------------------------------------------------------------------------------- // | |
// ----------------------------------------------------------------------------------- // | |
export interface Params { | |
[ key: string ]: any; |
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
SELECT | |
tmp.ipAddress, | |
-- Calculate how many connections are being held by this IP address. | |
COUNT( * ) AS ipAddressCount, | |
-- For each connection, the TIME column represent how many SECONDS it has been in | |
-- its current state. Running some aggregates will give us a fuzzy picture of what | |
-- the connections from this IP address is doing. | |
FLOOR( AVG( tmp.time ) ) AS timeAVG, |
NewerOlder