Skip to content
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

feat(*): remove canvas dependency #50

Merged
merged 3 commits into from
Jan 4, 2024
Merged

Conversation

stepancar
Copy link
Contributor

To build electron we need to solve this issue somehow
Automattic/node-canvas#2200

The easiest way to do that is to remove node canvas as a dependency

@@ -36,6 +35,7 @@
"@typescript-eslint/eslint-plugin": "^5.59.0",
"@typescript-eslint/parser": "^5.59.0",
"@vitest/ui": "^0.29.8",
"canvas": "^2.9.1",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we need canvas to run tests, I just moved it to devDeps

@@ -256,12 +255,12 @@ export class BeamcoderExtractor extends BaseExtractor implements Extractor {
return null;
}
const rawData = this._resizeFrameData(frame);
const image = createImageData(
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we will create this function in luminary instead

frame.width,
frame.height
) as ImageData;
return image;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It was nice to have ImageData type, but since it comes with complex build requirements, I think it makes sense to remove 😿

@stepancar stepancar merged commit 520eaa4 into main Jan 4, 2024
1 check passed
@stepancar stepancar deleted the feat/remove-canvas-deps branch January 4, 2024 19:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants