docs: use styled glamour markdown within viewport

This commit is contained in:
Maas Lalani 2022-09-23 15:41:33 -04:00 committed by Christian Rocha
parent e9fe942675
commit e5cbc04f94
1 changed files with 6 additions and 4 deletions

View File

@ -11,7 +11,9 @@ import (
) )
const content = ` const content = `
Todays Menu # Todays Menu
## Appetizers
| Name | Price | Notes | | Name | Price | Notes |
| --- | --- | --- | | --- | --- | --- |
@ -20,7 +22,7 @@ Todays Menu
| Okonomiyaki | $4 | Takes a few minutes to make | | Okonomiyaki | $4 | Takes a few minutes to make |
| Curry | $3 | We can add squash if youd like | | Curry | $3 | We can add squash if youd like |
Seasonal Dishes ## Seasonal Dishes
| Name | Price | Notes | | Name | Price | Notes |
| --- | --- | --- | | --- | --- | --- |
@ -28,7 +30,7 @@ Seasonal Dishes
| Takoyaki | $3 | Fun to eat | | Takoyaki | $3 | Fun to eat |
| Winter squash | $3 | Today it's pumpkin | | Winter squash | $3 | Today it's pumpkin |
Desserts ## Desserts
| Name | Price | Notes | | Name | Price | Notes |
| --- | --- | --- | | --- | --- | --- |
@ -64,7 +66,7 @@ func newExample() (*example, error) {
PaddingRight(2) PaddingRight(2)
renderer, err := glamour.NewTermRenderer( renderer, err := glamour.NewTermRenderer(
glamour.WithStylePath("notty"), glamour.WithAutoStyle(),
glamour.WithWordWrap(width), glamour.WithWordWrap(width),
) )
if err != nil { if err != nil {