UNPKG

@serenity-js/core

Version:

The core Serenity/JS framework, providing the Screenplay Pattern interfaces, as well as the test reporting and integration infrastructure

8 lines (6 loc) 273 B
import { JSONData } from './JSONData'; export class TextData extends JSONData { static fromJSON(value: { contentType: string, data: string }): TextData { return new TextData(Buffer.from(JSON.stringify(value, undefined, 0), 'utf8').toString('base64')); } }