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
{ | |
"Version": "2012-10-17", | |
"Id": "PutObjPolicy", | |
"Statement": [ | |
{ | |
"Sid": "DenyUnEncryptedObjectUploads", | |
"Effect": "Deny", | |
"Principal": "*", | |
"Action": "s3:PutObject", | |
"Resource": "arn:aws:s3:::oms-services.secrets/*", |
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
{ | |
"Version": "2012-10-17", | |
"Statement": [ | |
{ | |
"Effect": "Allow", | |
"Action": [ | |
"s3:DeleteObject", | |
"s3:GetObject", | |
"s3:GetObjectAcl", | |
"s3:PutObject", |
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
language: node_js | |
node_js: | |
- 6 | |
cache: | |
directories: | |
- vinhlh.static/node_modules | |
install: | |
# for invalidating CloudFront distribution |
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
language: node_js | |
node_js: | |
- 6 | |
cache: | |
directories: | |
- dir_1/node_modules | |
before_install: | |
- cd dir_1 |
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(modules) { | |
// The module cache | |
var installedModules = {}; | |
// The require function | |
function __webpack_require__(moduleId) { | |
// Check if module is in cache | |
if(installedModules[moduleId]) | |
return installedModules[moduleId].exports; |
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 React, { Component, PropTypes } from 'react' | |
import { PDF_VIEWER } from '../configs' | |
const propTypes = { | |
ratio : PropTypes.number, | |
file : PropTypes.string.isRequired | |
} | |
const defaultProps = { | |
ratio: 56.25 |
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
m.prototype.throttleSendRemoteQuery = function() { | |
'use strict'; | |
var n = c('FacebarGlobalOptions').sendRemoteQueryThrottleTime; | |
if (n === 0) { | |
this.sendRemoteQueryThrottled = this.sendRemoteQuery; | |
} else if (c('FacebarGlobalOptions').lazyThrottleRemoteQuery) { | |
var o = Date.now() | |
, p = c('FacebarGlobalOptions').enableSendRemoteQueryDelay | |
, q = c('FacebarGlobalOptions').sendRemoteQueryDelayTime; | |
this.sendRemoteQueryThrottled = function() { |
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
/** | |
* Setup Js error lazy tracking | |
* - Pros: doesn't block rendering, onload event | |
* - Cons: lower quality error reports for lazy errors | |
* | |
* @author vinhlh | |
* | |
* @param {object} window | |
* @param {object} labJs | |
* @param {string} ravenCdn |
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
package main | |
import ( | |
"fmt" | |
"log" | |
"os" | |
"github.com/aws/aws-sdk-go/aws" | |
"github.com/aws/aws-sdk-go/aws/credentials" | |
"github.com/aws/aws-sdk-go/aws/session" |
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
// Requirements | |
// - React Dev Tools is installed. | |
// | |
// 1. Select scrollable-holder > f listType=course | |
// 2. Open Console | |
// 3. Run | |
$r.props.list.lessons.map(({ download_url }) => download_url) | |
// It will return a list of URLs like this | |
["https://d3j4ov1z2pxjvg.cloudfront.net/lessons/eggh…Yk8rdCRrG717PA__&Key-Pair-Id=APKAIEGNPCBY26T6OCUQ", "https://d3j4ov1z2pxjvg.cloudfront.net/lessons/eggh…JqohRQd8QSziCQ__&Key-Pair-Id=APKAIEGNPCBY26T6OCUQ", "https://d3j4ov1z2pxjvg.cloudfront.net/lessons/eggh…CWI7XuOLvgo6gg__&Key-Pair-Id=APKAIEGNPCBY26T6OCUQ", "https://d3j4ov1z2pxjvg.cloudfront.net/lessons/eggh…ttRijk5eKVqmWg__&Key-Pair-Id=APKAIEGNPCBY26T6OCUQ", "https://d3j4ov1z2pxjvg.cloudfront.net/lessons/eggh…-BkUuXhdRKojMA__&Key-Pair-Id=APKAIEGNPCBY26T6OCUQ", "https://d3j4ov1z2pxjvg.cloudfront.net/lessons/eggh…KJ50oYPlKNYp4A__&Key-Pair-Id=APKAIEGNPCBY26T6OCUQ", "https://d3j4ov1z2pxjvg.cloudfront.net/lessons/eggh…PzTlKj~APZyNDw__&Key-Pair-Id=APKAIEGNPCBY26T6OCUQ", "https://d3j4ov1z2pxjvg.cloudfront.net/lessons/eggh…- |
OlderNewer