export function objectToRString(input, options) {
    if (!input)
        return '';
    if (typeof input === 'string')
        return JSON.stringify(input);
    return JSON.stringify(input, null, 1)
        .split('\n')
        .map((line, index, arr) => index === arr.length - 1 ? line : (options?.indent || ' ') + line)
        .join('\n')
        .trim();
}
export function postDataToRListBody(input, options) {
    const body = input
        .map(({ name, value }) => (options?.indent || '') + `${name} = "${value}"`)
        .join(',\n');
    return '\n' + body + '\n';
}
//# sourceMappingURL=utils.js.map