Skip to content

Commit

Permalink
Delay disposing image buffer.
Browse files Browse the repository at this point in the history
  • Loading branch information
bglgwyng committed Sep 4, 2024
1 parent f557667 commit 60dd37a
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions example/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,9 @@ export default function App() {
});

const data = Skia.Data.fromBytes(result);
updatePreviewImageFromData(data, TARGET_FORMAT);
data.dispose();
updatePreviewImageFromData(data, TARGET_FORMAT).then(() =>

Check failure on line 66 in example/src/App.tsx

View workflow job for this annotation

GitHub Actions / Lint JS (eslint, prettier)

Replace `↹↹↹` with `······`
data.dispose(),

Check failure on line 67 in example/src/App.tsx

View workflow job for this annotation

GitHub Actions / Lint JS (eslint, prettier)

Replace `↹↹↹↹data.dispose(),` with `········data.dispose()`
);

Check failure on line 68 in example/src/App.tsx

View workflow job for this annotation

GitHub Actions / Lint JS (eslint, prettier)

Replace `↹↹↹` with `······`
const end = performance.now();

console.log(
Expand Down

0 comments on commit 60dd37a

Please sign in to comment.