Sha256: c8835295758328b8baf79be36c052202c4d73c44e434f48e6a4de56871976223
Contents?: true
Size: 478 Bytes
Versions: 20
Compression:
Stored size: 478 Bytes
Contents
"use strict"; const enumerationValues = new Set([ "text/html", "text/xml", "application/xml", "application/xhtml+xml", "image/svg+xml" ]); exports.enumerationValues = enumerationValues; exports.convert = function convert(value, { context = "The provided value" } = {}) { const string = `${value}`; if (!enumerationValues.has(string)) { throw new TypeError(`${context} '${string}' is not a valid enumeration value for SupportedType`); } return string; };
Version data entries
20 entries across 20 versions & 1 rubygems