@quasarbright/projection
Version:
A static site generator that creates a beautiful, interactive gallery to showcase your coding projects. Features search, filtering, tags, responsive design, and an admin UI.
18 lines • 570 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.PROJECT_ID_PATTERN = void 0;
exports.isValidProjectId = isValidProjectId;
/**
* URL slug validation pattern for project IDs
* - Must be lowercase
* - Can contain letters, numbers, and hyphens
* - Cannot start or end with hyphen
*/
exports.PROJECT_ID_PATTERN = /^[a-z0-9]+(?:-[a-z0-9]+)*$/;
/**
* Validates if a string is a valid project ID (URL slug format)
*/
function isValidProjectId(id) {
return exports.PROJECT_ID_PATTERN.test(id);
}
//# sourceMappingURL=project.js.map