Compare commits
1 Commits
master
...
release/0.
Author | SHA1 | Date | |
---|---|---|---|
![]() |
1c1d63d5a3 |
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "LiteRyzJS",
|
"name": "LiteRyzJS",
|
||||||
"version": "0.1.0.455",
|
"version": "0.2.0.058",
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"css-loader": "^7.1.2",
|
"css-loader": "^7.1.2",
|
||||||
"sass": "^1.77.8",
|
"sass": "^1.77.8",
|
||||||
|
@ -7,3 +7,4 @@ import './extensions/math.js';
|
|||||||
import './extensions/object.js';
|
import './extensions/object.js';
|
||||||
import './extensions/string.js';
|
import './extensions/string.js';
|
||||||
import './extensions/window.js';
|
import './extensions/window.js';
|
||||||
|
import './extensions/file.js';
|
||||||
|
9
src/extensions/file.js
Normal file
9
src/extensions/file.js
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
String.prototype.getFilename = function () {
|
||||||
|
return this.substring(this.lastIndexOf('/') + 1);
|
||||||
|
};
|
||||||
|
|
||||||
|
String.prototype.getFileExtension = function () {
|
||||||
|
const filename = this.getFilename();
|
||||||
|
|
||||||
|
return filename.substring(filename.lastIndexOf('.') + 1).toLowerCase();
|
||||||
|
};
|
@ -76,8 +76,4 @@ String.prototype.toTitleCase = function () {
|
|||||||
result = result.charAt(0).toUpperCase() + result.substr(1);
|
result = result.charAt(0).toUpperCase() + result.substr(1);
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
};
|
|
||||||
|
|
||||||
String.prototype.getFilename = function () {
|
|
||||||
return this.substring(this.lastIndexOf('/') + 1);
|
|
||||||
};
|
};
|
Loading…
Reference in New Issue
Block a user