This file contains hidden or 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, { unstable_Profiler as Profiler } from 'react'; | |
... | |
const Profiler = React.unstable_Profiler; |
This file contains hidden or 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, unstable_Profiler as Profiler } from "react"; | |
import { render } from "react-dom"; | |
class ComponentWithProfiling extends Component { | |
state = { | |
count: 0 | |
}; | |
logProfile = (id, phase, actualTime, baseTime, startTime, commitTime) => { | |
console.log(`${id}'s ${phase} phase:`); |
This file contains hidden or 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
{ | |
"scripts": { | |
"build": "cross-env NODE_ENV=production node app.js" | |
} | |
} |
This file contains hidden or 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
set | |
ALLUSERSPROFILE=C:\ProgramData | |
APPDATA=C:\Users\user\AppData\Roaming | |
. | |
. | |
. | |
windir=C:\Windows |
This file contains hidden or 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
MYAPIKEY=ndsvn2g86nsb9hsg |
This file contains hidden or 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 myAPIKey = process.env.MYAPIKEY; | |
const url = 'https://externalapi.service.com/v1/query?key=' + myAPIKey; | |
const result = fetch(url); |
This file contains hidden or 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
node | |
> console.log(process.env) | |
{ GIT_PS1_SHOWDIRTYSTATE: '1', | |
NVM_RC_VERSION: '', | |
... | |
... | |
... | |
_: '/usr/local/bin/node', | |
__CF_USER_TEXT_ENCODING: '0x1F5:0x0:0x0' } |
This file contains hidden or 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 myAPIKey = 'ndsvn2g86nsb9hsg'; | |
const url = 'https://externalapi.service.com/v1/query?key=' + myAPIKey; | |
const result = fetch(url); |
This file contains hidden or 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
var request = require('request-promise'); | |
var main = function() { | |
var myAPIKey = process.env.MYAPIKEY; | |
var url = 'https://externalapi.service.com/v1/query?key=' + myAPIKey; | |
return request(url); | |
}; |
This file contains hidden or 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
var request = require('request-promise'); | |
var main = function() { | |
var myAPIKey = 'ndsvn2g8dnsb9hsg'; | |
var url = 'https://externalapi.service.com/v1/query?key=' + myAPIKey; | |
return request(url); | |
}; |