🎉 feat(formatter): add base FieldFormatter class for formatting template fields

The base.py file is a new addition to the project. It introduces the FieldFormatter class, which is an abstract base class (ABC) for formatting template fields. This class provides a format() method that takes a TemplateField object as input and is meant to be implemented by subclasses. This addition allows for the creation of custom field formatters in the project.
This commit is contained in:
Gabriel Luiz Freitas Almeida 2023-06-29 08:52:21 -03:00
commit 75f0a80ded
2 changed files with 9 additions and 0 deletions

View file

@ -0,0 +1,9 @@
from abc import ABC, abstractmethod
from langflow.template.field.base import TemplateField
class FieldFormatter(ABC):
@abstractmethod
def format(self, field: TemplateField):
pass