Skip to content

Commit eafe326

Browse files
committed
Update README.md
1 parent 633f77b commit eafe326

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

README.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,15 @@ JSON2Video makes video creation easy as a piece of cake:
7777

7878
// Call the API and render the movie
7979
movie.render();
80+
81+
// Wait for the movie to finish rendering
82+
movie
83+
.waitToFinish((status) => {
84+
console.log("Rendering: ", status.movies[0].status, " / ", status.movies[0].task);
85+
})
86+
.then((status) => {
87+
console.log("Movie is ready: ", status.movies[0].url);
88+
});
8089
```
8190

8291
This is the resulting video:

0 commit comments

Comments
 (0)