Skip to content

fix-172 #175

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jan 28, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 12 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -118,15 +118,23 @@ You can convert it to its string representation in JSON or YAML format
by using the static methods `Workflow.toJson` or `Workflow.toYaml` respectively:

```typescript
import { Workflow } from '../src/lib/definitions/workflow';
import {Specification, workflowBuilder} from "@severlessworkflow/sdk-typescript";

const workflowAsJson: string = Workflow.toJson(workflow);
const workflow: Specification.Workflow = workflowBuilder()
//...
.build()

const workflowAsJson: string = Specification.Workflow.toJson(workflow);
```

```typescript
import { Workflow } from '../src/lib/definitions/workflow';
import {Specification, workflowBuilder} from "@severlessworkflow/sdk-typescript";

const workflow: Specification.Workflow = workflowBuilder()
//...
.build()

const workflowAsYaml: string = Workflow.toYaml(workflow);
const workflowAsYaml: string = Specification.Workflow.toYaml(workflow);
```


Expand Down