Handy Parenscript macros.
This software is still BETA quality. The APIs will be likely to change.
This system can be installed from UltraLisp like this:
(ql-dist:install-dist "http://dist.ultralisp.org/"
:prompt nil)
(ql:quickload "parenboost")Checks if the length of val is greater than len.
Checks if the length of val is less than len.
Checks if the length of val is equal to len.
Checks if the val is empty.
Checks if the val is undefined.
Checks if the val is defined.
Checks if the val is NaN.
Checks if the val is finite.
Creates a new instance of a class with the specified arguments.
Throws an error.
Encodes a URI.
Decodes a URI.
Encodes URI components.
Decodes URI components.
Checks if a URL can be parsed, optionally with a base.
Parses a URL, optionally with a base.
Gets the character at the specified index.
Gets the character code at the specified index.
Gets the code point at the specified index.
Concatenates strings. Alias: strcat.
Checks if a string ends with the specified substring.
Checks if a string includes the specified substring. Alias: str-contains-p.
Finds the index of the specified substring.
Finds the last index of the specified substring.
Matches a string against a regular expression.
Matches a string against a regular expression, returning all matches.
Normalizes the string.
Repeats the string for the specified count.
Replaces the specified substring.
Replaces all instances of the specified substring.
Searches for a pattern in the string.
Slices the string.
Splits the string.
Checks if a string starts with the specified substring.
Gets a substring of the string.
Converts the string to lowercase.
Converts the string to uppercase.
Trims leading and trailing spaces from the string.
Splits the string into lines.
Creates a new promise.
Creates a promise that resolves when all promises in the iterable resolve.
Creates a promise that resolves when all promises in the iterable are settled.
Creates a promise that resolves when any of the promises resolve.
Creates a promise that resolves or rejects when the first promise settles.
Creates a promise that rejects with the specified reason.
Creates a promise that resolves with the specified value.
Attempts to execute a function within a promise context.
Creates a promise and provides resolve and reject handlers.
Creates a new Hash (JS Map object).
Creates a new Weak Hash (JS WeakMap object).
Checks if the hash is Map object.
Sets a value in the hash.
Gets a value from the hash.
Clears all entries in the hash.
Deletes a specific key-value pair.
Checks if a hash contains a specified key.
Checks if a hash contains a specified key.
Gets size of hash.
Parses a JSON string.
converts a value to a JSON string.
Reduces the iterator to a single value.
Applies a function to each element of the iterator.
Filters and maps the elements of the iterator.
Checks if every element satisfies a condition.
Checks if an object is an HTML element.
Gets an element by its ID.
Adds an event listener to an element.
Logs messages to the console.
Logs a debug message to the console.
Logs an info message to the console.
Logs a warning message to the console.
Logs an error message to the console.
Logs a message to the console if the given assertion evaluates to false.
Starts a timer with the specified label, which can be used to measure the duration of code execution.
Stops the timer with the specified label and logs the elapsed time to the console.