Last active
November 27, 2018 01:06
-
-
Save chris-sev/efe7fe257c9bfdc4d81aa654ddbb5bec to your computer and use it in GitHub Desktop.
Quick Example
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
// 1. create a message | |
const message = 'This is my message.'; | |
// 2. replace message with new thing | |
// this creates a brand new string. does not change the original variable (message) | |
const newMessage = message.replace('message', 'new thing'); | |
// 3. output: This is my new thing. | |
console.log(newMessage); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment