diff --git a/docs/FAQ.rst b/docs/FAQ.rst index 909fa2c1a6442168b41f89efa81de477301fb6ed..5d9bb330ff485c1c546b2d16319a2720b3d07ec4 100644 --- a/docs/FAQ.rst +++ b/docs/FAQ.rst @@ -22,14 +22,20 @@ Frequently Asked Questions (FAQs) Sample usages: .. code-block:: python + from importlib_resources import path with path(package, resource) as file_in: new_grid = np.load(file_in) + + And: .. code-block:: python + from importlib_resources import read_binary + load_data = read_binary(package, resource) self.set_full_state_msg(load_data) + .. _importlib-resources: https://importlib-resources.readthedocs.io/en/latest/