mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/izyim-mockapi.git
synced 2026-08-28 08:54:23 +00:00
added necessary npm packages
This commit is contained in:
+20
@@ -0,0 +1,20 @@
|
||||
"use strict";
|
||||
|
||||
module.exports = {
|
||||
JSON,
|
||||
JS,
|
||||
URL
|
||||
};
|
||||
|
||||
function JSON(s) {
|
||||
return !URL(s) && /\.json$/.test(s);
|
||||
}
|
||||
|
||||
function JS(s) {
|
||||
return !URL(s) && /\.js$/.test(s);
|
||||
}
|
||||
|
||||
function URL(s) {
|
||||
return (/^(http|https):/.test(s)
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user