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

blueimp-md5: blueimp.md5 is not a function #8996

Closed
3 tasks done
Zzzen opened this issue Apr 15, 2016 · 4 comments
Closed
3 tasks done

blueimp-md5: blueimp.md5 is not a function #8996

Zzzen opened this issue Apr 15, 2016 · 4 comments

Comments

@Zzzen
Copy link
Contributor

Zzzen commented Apr 15, 2016

  • I tried using the latest blueimp-md5.d.ts file in this repo and had problems.
  • I tried using the latest stable version of tsc. https://www.npmjs.com/package/typescript
  • I want to talk about xxxx/xxxx.d.ts.
    Error occurs when I try to use the definition file like this hashed = require("blueimg-md5").md5("my string").
    From npm page, we can see that the export of this module is simply a function.
    // Use the following version if you installed the package with npm: 
        var md5 = require("blueimp-md5"), 
        query = url.parse(req.url).query;
    // Calculate and print the MD5 hash of the url query: 
    res.end(md5(query));

The definition should be

declare module 'blueimp-md5' {
    function md5(value: string, key?: string, raw?: boolean): string;
    export = md5;
}

rather than

declare module 'blueimp-md5' {
    export function md5(value: string, key?: string, raw?: boolean): string;
}
@otobrglez
Copy link

I have the same problem. ;| Definition is still the same.

@ghost
Copy link

ghost commented Oct 1, 2016

me too.

@vvakame
Copy link
Member

vvakame commented Oct 3, 2016

please send a pull request. I'll review it.

@orta
Copy link
Collaborator

orta commented Jun 7, 2021

Hi thread, we're moving DefinitelyTyped to use GitHub Discussions for conversations the @types modules in DefinitelyTyped.

To help with the transition, we're closing all issues which haven't had activity in the last 6 months, which includes this issue. If you think closing this issue is a mistake, please pop into the TypeScript Community Discord and mention the issue in the definitely-typed channel.

@orta orta closed this as completed Jun 7, 2021
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

No branches or pull requests

4 participants