You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@gignupg seems like its a year old request, are you planning to support buffer/steam in the future? i tested ur work and i would say its more accurate than chardet package.
I'll try to create a PR myself if i find some time
@gfreecs0510 That's a huge compliment, thanks a lot!
Regarding the buffer feature, I wasn't planning on implementing it myself, but I know that a lot of people have requested it, so a PR would be very welcome!
@davuses thx for the code snippet! Would you want to implement it and do a PR? I'm a little bit busy at the moment...
It's probably not necessary to make changes to the code, like I said above the current API can handle buffer as long as you make a blob object out of it, it's quite simple. So maybe add a snippet demo to show how this could be done in readme file.
Activity
gignupg commentedon Dec 20, 2021
Sure, we could add that option. I'll accept the pull request if you do one!
gfreecs0510 commentedon Jan 12, 2023
@gignupg seems like its a year old request, are you planning to support buffer/steam in the future? i tested ur work and i would say its more accurate than
chardetpackage.I'll try to create a PR myself if i find some time
gignupg commentedon Jan 13, 2023
@gfreecs0510 That's a huge compliment, thanks a lot!
Regarding the buffer feature, I wasn't planning on implementing it myself, but I know that a lot of people have requested it, so a PR would be very welcome!
davuses commentedon Mar 20, 2023
You can create a blob object from the buffer and pass it as argument to the API, something like:
This should work
gignupg commentedon Mar 24, 2023
@davuses thx for the code snippet! Would you want to implement it and do a PR? I'm a little bit busy at the moment...
davuses commentedon Mar 24, 2023
It's probably not necessary to make changes to the code, like I said above the current API can handle buffer as long as you make a blob object out of it, it's quite simple. So maybe add a snippet demo to show how this could be done in readme file.
gignupg commentedon Mar 29, 2023
Thx @davuses for clarifying! I added a link to your code snipped in the readme and published a new version to NPM!
erkstruwe commentedon Jun 23, 2023
This only works in the browser. I added a PR for support in Node.js: #12.