Metadata-Version: 2.1
Name: mkdocstrings-vba
Version: 0.0.10
Summary: MkDocstrings VBA handler
Home-page: https://github.com/AutoActuary/mkdocstrings-vba
Author: Rudolf Byker
Author-email: rudolfbyker@gmail.com
Classifier: Programming Language :: Python :: 3
Classifier: License :: Other/Proprietary License
Classifier: Operating System :: OS Independent
Requires-Python: >=3.7
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: mkdocstrings<1,>=0.26.1
Requires-Dist: griffe<2,>=1.3.1
Requires-Dist: mkdocs-material<10,>=9.2

# mkdocstrings-vba

A VBA handler for [mkdocstrings](https://github.com/mkdocstrings/mkdocstrings).

Since there is no official way of documenting VBA functions, we have opted for
the [Google Docstring format](https://google.github.io/styleguide/pyguide.html#38-comments-and-docstrings) commonly used
in Python projects. This is conveniently parsed by the [`griffe`](https://mkdocstrings.github.io/griffe) library which
is also used by [`mkdocstrings[python]`](https://mkdocstrings.github.io/python/). The argument types and return types
are taken from the
VBA [Function](https://learn.microsoft.com/en-us/office/vba/language/reference/user-interface-help/function-statement)
or [Sub](https://learn.microsoft.com/en-us/office/vba/language/reference/user-interface-help/sub-statement) signatures,
which we parse using [regex](https://regular-expressions.info).

## Examples

See the [`examples`](https://github.com/mkdocstrings/vba/tree/master/examples) folder.

To build an example site:

1. `pip install mkdocstrings mkdocstrings-vba`
2. `cd examples/example1`
3. View the source code.
4. `mkdocs build`
5. cd `site/`
6. View the results.

## Running tests

```shell
pip install -r test-requirements.txt
python -m unittest
```

This will run all tests. This includes

- Unit tests from `tests/`.
- Doctests from `mkdocstrings_vba/`.
- Full builds from `examples/`.

## Linting

Fix code style using `black`:

```shell
black .
```

Check types using `mypy`:

```shell
mypy .
```
