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
// See: https://www.youtube.com/watch?v=HaEPXoXVf2k | |
const AWS = require('aws-sdk'); | |
AWS.config.update({region: 'us-east-1'}); | |
const dynamoDb = new AWS.DynamoDB.DocumentClient({ api_version: '2012-08-10' }); | |
const TABLE = 'single-table-design'; | |
const GSI1 = 'gsi1'; | |
const GSI1PK = `${GSI1}pk`; | |
const GSI1SK = `${GSI1}sk`; |
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
const AWS = require('aws-sdk'); | |
AWS.config.update({region: 'us-east-1'}); | |
const dynamoDb = new AWS.DynamoDB.DocumentClient({ api_version: '2012-08-10' }); | |
const TABLE = 'single-table-design'; | |
const GSI1 = 'gsi1'; | |
const GSI1PK = `${GSI1}pk`; | |
const GSI1SK = `${GSI1}sk`; | |
const GSI2 = 'gsi2'; | |
const GSI2PK = `${GSI2}pk`; |
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
app.directive('hasDropdown', function ($window, $timeout) { | |
return { | |
restrict: 'A', | |
replace: false, | |
link: function (scope, elm, attrs) { | |
elm.bind("click", open); | |
function open(e) { | |
elm[0].classList.add("open"); | |
$timeout(function () { |