Son CV dans un terminal web en Javascript!
https://terminal-cv.gregandev.fr
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
359 B
17 lines
359 B
1 year ago
|
"use strict";
|
||
|
|
||
|
Object.defineProperty(exports, "__esModule", {
|
||
|
value: true
|
||
|
});
|
||
|
exports.default = validateModuleSpecifier;
|
||
|
const MODULE_REGEX = /^((@[^/\s]+\/){0,1}([^/\s.~]+[^/\s]*)){1}(@[^/\s]+){0,1}/;
|
||
|
|
||
|
function validateModuleSpecifier(moduleName) {
|
||
|
let matches = MODULE_REGEX.exec(moduleName);
|
||
|
|
||
|
if (matches) {
|
||
|
return matches[0];
|
||
|
}
|
||
|
|
||
|
return '';
|
||
|
}
|