ocat-lang
Version:
A programming language for the web design and development
18 lines (17 loc) • 479 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.Lexical = void 0;
const error_1 = require("../error");
const Lexical = (input) => {
if (input) {
return input
.replace(/\n/g, " \n ")
.split(" ")
.map((word) => word.trim());
}
else {
throw new error_1.CustomError("Please provide a valid input", error_1.ErrorType.RuntimeError);
}
return [];
};
exports.Lexical = Lexical;