String Converter Node

This commit is contained in:
nofunstudio
2025-06-23 21:51:21 -06:00
parent fa970a551a
commit ef5b94c0d5
2 changed files with 22 additions and 2 deletions
+17
View File
@@ -0,0 +1,17 @@
class StringLower:
CATEGORY = "Text" # shows up under "Text" in the node picker
@classmethod
def INPUT_TYPES(cls):
return {
"required": {
"text": ("STRING",), # one STRING input
}
}
RETURN_TYPES = ("STRING",) # one STRING output (fixed syntax error)
FUNCTION = "to_lower" # name of the method to call
def to_lower(self, text):
# do the work and return a tuple matching RETURN_TYPES
return (text.lower(),)