A question that always teases me when I'm in a Java project in which we use terms in Portuguese is to deal with method names or variables that represent somehow two things and need to mention both in the method / variable name. In English, and i...
How can I separate "words" into CamelCase using hyphen for example?
With a string:
string example = "CamelCase";
// CamelCase para:
// Camel-Case
and enumerator:
enum Example {
CamelCase
}
Example.CamelCase.ToString();
// CamelC...
I already have a function where it performs the conversion of strings to slug .
Below I will give examples for facilitation in understanding my question.
3 examples before conversion:
link para uma página
link página...
How can I convert a string pythonic to snake_case in%% possible?
Example:
snake1 = 'minha_string_snake_case' # minhaStringSnakeCase
snake2 = '_teste_string' # _TestString