Skip to main content
Version: 0.4.3

MixinFile

ClassExtensionSource

mixin = MixinFile()

Mixin of providing file loading functionalities.

Methods

from_str

mixin = MixinFile.from_str(json_string: str, *args, **kwargs)

from_str is a class method, returning the instance created by this method.

Use a JSON string to initialize the component.

If using this method, users should leave the argument data blank because this method will load json_string and pass it to the data argument.

To find more details about the arguments, see DashJsonGrid.


from_file

mixin = MixinFile.from_file(
json_file: str | os.PathLike | IO[str], *args, **kwargs
)

from_file is a class method, returning the instance created by this method.

Use a JSON file to initialize the component.

If using this method, users should leave the argument data blank because this method will load json_file and pass it to the data argument.

To find more details about the arguments, see DashJsonGrid.