• Parses the stringified tags and returns a set of tags. Accepts a delimiter to split the stringified tags.

    Parameters

    • stringifiedTags: string

      The string tags to parse

    • Optionaldelimiter: string | RegExp

      The delimiter to split the strings of tags. Accepts a string or a RegExp Defaults to /\s+/. Note: While it is optional, if your string of tags contains spaces within the tag, it is recommended to have a custom delimiter as a lot of tags have spaces some even have special characters.

    Returns Set<Tag>

    • A set of tags in Tag format. (Original node-hitomi had an array of tags but due to speed constraints, it was changed to a set)
    • If the tag type is not valid.
    getParsedTags('language:korean+-female:big breasts+type:doujinshi', '+');
    // Output:
    // Set { { type: 'language', name: 'korean', isNegative: false },
    // { type: 'female', name: 'big breasts', isNegative: true },
    // { type: 'type', name: 'doujinshi', isNegative: false } }