About 50 results
Open links in new tab
  1. javascript - How do you reverse a string in-place? - Stack Overflow

    How do you reverse a string in-place in JavaScript when it is passed to a function with a return statement, without using built-in functions (.reverse(), .charAt() etc.)?

  2. javascript - Converting a string with spaces into camel case - Stack ...

    Mar 19, 2019 · How can I convert a string into camel case using javascript regex? EquipmentClass name or Equipment className or equipment class name or Equipment Class Name should all …

  3. How do I make the first letter of a string uppercase in JavaScript ...

    Jun 22, 2009 · How do I make the first character of a string uppercase if it's a letter, but not change the case of any of the other letters? For example: "this is a test" → "This is a test" ...

  4. Javascript custom functions with string - Stack Overflow

    Jan 30, 2018 · 2 A JavaScript string will inherit functions from its prototype, so you need to add the function to the string prototype. For example:

  5. How can I capitalize the first letter of each word in a string using ...

    That means it does not necessarily convert words to Titlecase, but does exactly what the title of the question says: "Capitalize First Letter Of Each Word In A String - JavaScript"

  6. How do I split a string with multiple separators in JavaScript?

    Mar 16, 2009 · How do I split a string with multiple separators in JavaScript? I'm trying to split on both commas and spaces, but AFAIK JavaScript's split() function only supports one separator.

  7. Reversing a string in JavaScript - Stack Overflow

    May 27, 2017 · To answer your initial question — how to [properly] reverse a string in JavaScript —, I’ve written a small JavaScript library that is capable of Unicode-aware string reversal. It doesn’t have any …

  8. How can you encode/decode a string to Base64 in JavaScript?

    You can use btoa() and atob() to convert to and from base64 encoding. There appears to be some confusion in the comments regarding what these functions accept/return, so… btoa() accepts a …

  9. Pass a string parameter in an onclick function - Stack Overflow

    A couple of concerns for me with respect to using string escape in onClick and as the number of arguments grow, it will become cumbersome to maintain. The following approach will have a one hop …

  10. How do I check for an empty/undefined/null string in JavaScript?

    It works on a null string, and on an empty string and it is accessible for all strings. In addition, it could be expanded to contain other JavaScript empty or whitespace characters (i.e. nonbreaking space, byte …