-
Notifications
You must be signed in to change notification settings - Fork 3
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
DEP0005
: Buffer()
is deprecated due to security and usability issues
#3
Comments
Sorry for the slow answer, and thank you for suggesting this fix/update! :) After merging your fix, I tried updating PDF.js to the current last version (4.0.379), but it seems like they switched to ES modules starting from major version 4, which are—as far as I know—not readily compatible with the architecture of i-LaTeX's webview. However, the last release before that change, version 3.11.174, seems to work just fine. 671cae1 updates the code to use this version instead, which, indeed, does not seem to instantiate any |
That function was deprecated as per nodejs/node#4660.
While manually installing the extension, the following warning appears:
With
--trace-deprecation
we can locate where the deprecated function is being used:The following is the line that's causing this:
ilatex/src/webview/template/static/js/pdf.js
Line 21298 in 822b590
To achieve the migration, we need to change its syntax:
In the codebase:
Additionally,
i-LaTeX
is using version2.3.200
ofpdf.js
:ilatex/src/webview/template/static/js/pdf.js
Line 127 in 822b590
Last release of
pdf.js
currently is 3.9.179 and lacks this issue, so upgrading the dependency is another option to be considered.The text was updated successfully, but these errors were encountered: