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

Refactor to simpler JS #55

Open
wants to merge 22 commits into
base: master
Choose a base branch
from
Open

Conversation

coolaj86
Copy link
Contributor

@coolaj86 coolaj86 commented Jan 26, 2023

This is in preparation for a larger refactor to update to modern, cross-platform async WebCrypto, Uint8Array, nobleSecp256k1, etc.

  • make Prettier
  • pass stricter lint rules
  • use UMD-ish exports
  • remove prototypes (in favor of plain object)
  • remove defineProperty getter/setter (in favor of plain getXyz()s)
  • remove assert
  • remove safe-buffer
  • updated mocha tests
  • added Types 🎉
  • Changed a few assert(x, msg) to if (!x) { throw new Error(msg) } to satisfy tscs style of nullish checking.

I actually meant to PR this onto my own fork, but... I think it could serve well here too for a v3.

The individual commits are very atomic as to be easy to read and reason about.

@coolaj86 coolaj86 changed the title chore: add types and minor changes for type checking Refactor to simpler JS Jan 26, 2023
@coolaj86 coolaj86 force-pushed the ref-types branch 2 times, most recently from 6aaefa7 to 61630a8 Compare February 3, 2023 05:50
@coolaj86 coolaj86 force-pushed the ref-types branch 2 times, most recently from 316d8ae to e2ca7c3 Compare February 3, 2023 09:27
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

Successfully merging this pull request may close these issues.

None yet

1 participant