Created
November 14, 2017 16:36
-
-
Save nolochemical/b6ab208283ab3ca673204e03190c58b6 to your computer and use it in GitHub Desktop.
Escape Variables ES6
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
/* Template literals | |
Ascii 96 || html ` | |
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_literals | |
.*/ | |
hostname = "kruger" | |
port = 8080 | |
console.log(`Server running at http://${hostname}:${port}/`); | |
//Server running at http://kruger:8080/ | |
console.log(`Server running at | |
http://${hostname}:${port}/`); | |
// Server running at | |
// http://kruger:8080/ | |
console.log("Server running at http://${hostname}:${port}/"); | |
//Server running at http://${hostname}:${port}/ | |
console.log('Server running at http://${hostname}:${port}/'); | |
//Server running at http://${hostname}:${port}/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment