1.6.7 • Published 7 years ago

electrum-utils v1.6.7

Weekly downloads
20
License
MIT
Repository
github
Last release
7 years ago

Electrum utilities

React components which work with Electrum might need some of the functionality provided by these utility functions.

  • getInstanceMethodNames (obj, stop) gets an array of method names by walking obj's prototype chain until (optional) prototype stop is reached.
    See Enumerating methods on a JavaScript class instance for a discussion on how this works.

  • getTextSelection (element) gets the selection as an object containing a from and a to position. Example selection: {from: 3, to: 8}. Cursor position without selection: from: 3, to: 3}.

  • shallowEqual (objA, objB) returns true if both objects contain the same keys and values (the comparison is done by reference equality).

  • startsWithLowerCase (string) returns true if the text starts with a lower case character (a-z, no accented characters).

  • startsWithUpperCase (string) returns true if the text starts with an upper case character (A-Z, no accented characters).

1.6.7

7 years ago

1.6.6

7 years ago

1.6.5

7 years ago

1.6.4

7 years ago

1.6.3

7 years ago

1.6.2

7 years ago

1.6.1

7 years ago

1.6.0

8 years ago

1.5.1

8 years ago

1.5.0

8 years ago

1.4.0

8 years ago

1.3.0

8 years ago

1.2.0

8 years ago

1.1.0

8 years ago

1.0.0

8 years ago

0.0.2

8 years ago

0.0.1

9 years ago