-
-
Save OlivierJM/2d096363f93f8d2097f0e47c2dff126b to your computer and use it in GitHub Desktop.
Regex to remove file extension from JS string.
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
var filenameFull = "tm_icons.png"; | |
//Regex to remove | |
var filenameText = filenameFull.replace(/\.[^/.]+$/, ""); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment