## GreatDocs.preview()


Preview the documentation site locally.


Usage

``` python
GreatDocs.preview(port=3000)
```


Starts a local HTTP server and opens the built site in the default browser. If the site hasn't been built yet, it will be built first. Use `great-docs build` to rebuild the site if you've made changes.

> **Note: Note**
>
> In practice, you would normally use the `great-docs preview` CLI command rather than calling this method directly. See the [CLI reference](cli/preview.md) for details.


## Parameters


`port: int = ``3000`  
The port number for the local HTTP server (default `3000`).


## Examples

Preview the documentation:

``` python
from great_docs import GreatDocs

docs = GreatDocs()
docs.preview()
```
