]> git.codecow.com Git - libnemo.git/commitdiff
Alphabetize object props.
authorChris Duncan <chris@codecow.com>
Tue, 30 Jun 2026 20:53:53 +0000 (13:53 -0700)
committerChris Duncan <chris@codecow.com>
Tue, 30 Jun 2026 20:53:53 +0000 (13:53 -0700)
src/lib/convert/base32.ts

index 4e554c1ccc9489ea64430aeb8586486130272dad..f4bbc9ec22e3aee102734f38df2be674834649da 100644 (file)
@@ -4,6 +4,16 @@
 import { ALPHABET } from '../constants'
 
 export const base32 = Object.freeze({
+       /**
+        * Convert a base32 string to an ArrayBuffer.
+        *
+        * @param {string} base32 - String to convert
+        * @returns {Uint8Array} Byte array representation of the input string
+        */
+       toBuffer (base32: string): ArrayBuffer {
+               return this.toBytes(base32).buffer
+       },
+
        /**
         * Convert a base32 string to a Uint8Array of bytes.
         *
@@ -40,14 +50,4 @@ export const base32 = Object.freeze({
                }
                return output
        },
-
-       /**
-        * Convert a base32 string to an ArrayBuffer.
-        *
-        * @param {string} base32 - String to convert
-        * @returns {Uint8Array} Byte array representation of the input string
-        */
-       toBuffer (base32: string): ArrayBuffer {
-               return this.toBytes(base32).buffer
-       },
 })