Test, validate and match regular expressions
This regex matches at the start of a string only if the first character is not a forward slash. It's commonly used when adding prefixes to file paths or folder names to ensure you don't add a prefix to paths that already start with '/'. The lookahead assertion checks for this condition without consuming characters, making it ideal for conditional string manipulation in filesystem operations.