index.js
function serializeProperty(metadata, prop) {
    if (!metadata || metadata.excludeToJson === true) {
        return;
    }
    if (metadata.customConverter) {
        return metadata.customConverter.toJson(prop);
    }
    if (!metadata.clazz) {
        return prop;
    }
    if (utils_1.isArrayOrArrayClass(prop)) {
        return prop.map(function (propItem) { return serialize(propItem); });
    }
    return serialize(prop);
}
function serializeProperty(metadata, prop) {
    if (!metadata || metadata.excludeToJson === true) {
        return;
    }
    if (metadata.customConverter) {
        return metadata.customConverter.toJson(prop);
    }
    if (!metadata.clazz) {
        return prop;
    }
    if (utils_1.isArrayOrArrayClass(prop)) {
        return prop.map(function (propItem) { return serialize(propItem); });
    }
    return serialize(prop);
}
function serializeProperty ( metadata , prop ) { if ( ! metadata || metadata . excludeToJson === true ) { return ; } if ( metadata . customConverter ) { return metadata . customConverter . toJson ( prop ) ; } if ( ! metadata . clazz ) { return prop ; } if ( utils_1 . isArrayOrArrayClass ( prop ) ) { return prop . map ( function ( propItem ) { return serialize ( propItem ) ; } ) ; } return serialize ( prop ) ; }
Prepare a single property to be serialized to JSON.

@param metadata
@param prop
@returns {any}
Prepare a single property to be serialized to JSON .