Created
December 18, 2019 00:09
-
-
Save shawncampbell/2e0595164dfb3b0874635bad212318c6 to your computer and use it in GitHub Desktop.
Log Heroku Config Vars as JSON object in Console
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
// Run jQuery in Console | |
// @see https://blog.wplauncher.com/run-jquery-in-chrome-console/ | |
var jqry = document.createElement('script'); | |
jqry.src = "https://code.jquery.com/jquery-3.3.1.min.js"; | |
document.getElementsByTagName('head')[0].appendChild(jqry); | |
jQuery.noConflict(); | |
// Log Heroku Config Vars as JSON in Console | |
// @see https://blog.wplauncher.com/backup-heroku-config-vars/ | |
var config_vars = {} | |
$( '.config-var-key' ).each( | |
function(){ | |
var key = $( this ).val() | |
var value = $( this ).parents( 'tr' ).find( '.config-var-value' ).eq(0).val() | |
config_vars[key] = value | |
} | |
) | |
console.log( config_vars ) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment