Skip to content

var random = new Random.Random() does not work when random-js is imported as a script #59

@atbenmurray

Description

@atbenmurray

Thanks for this library, I'm unfortunately struggling to make use of it in script form, as indicated by the documentation.

Code snippet as follows:

  <script src="https://cdnjs.cloudflare.com/ajax/libs/random-js/1.0.8/random.min.js""></script>
  <script>
    var random = new Random.Random();
  </script>

This gives the following response:

Uncaught TypeError: Random.Random is not a constructor

Please could you advise on how to use the library in the above circumstance?

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