Skip to content

Request: encode to hex #406

Open
Open
@VerlindenEAM

Description

@VerlindenEAM

Would it be possible to get hex encoding helper?

We have some search related features using your Handlebars Helpers and it would be great to use the hex encoding in our URL mechanism.

For example:
"Analytics" would result in hex code "416e616c7974696373"
"Encode - Hex" would result in hex code "456e636f6465202d20486578"

var t = "Analytics"
var h = "";
for (let i=0; i<t.length; i++) {
h+= t.charCodeAt(i).toString(16);
}

console.log(t); // original text
console.log(h); // hex string

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions