Skip to content

TypeError: _crypto2.default.createHash is not a function #5

Open
@dmitry-grinko

Description

@dmitry-grinko

I am trying to use it on my Angular app.

import * as aws4 from 'hyper-aws4';

test() {
    const creds = this.awsService.getFederateIdentityCredentials();
    const signOption = {
        url: 'http://google.com',
        credential: {
          accessKey: creds.accessKeyId,
          secretKey: creds.secretAccessKey
        }
      }
    const headers = aws4.sign(signOption);
    console.log(headers);
}

but I get this error:

TypeError: _crypto2.default.createHash is not a function

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions