https://github.com/bep/goportabletext
Converts Portable Text to Markdown.
https://github.com/bep/goportabletext
Last synced: 3 months ago
JSON representation
Converts Portable Text to Markdown.
- Host: GitHub
- URL: https://github.com/bep/goportabletext
- Owner: bep
- License: mit
- Created: 2025-02-19T08:57:29.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2025-02-26T13:18:33.000Z (about 1 year ago)
- Last Synced: 2025-04-23T14:19:53.135Z (about 1 year ago)
- Language: Go
- Homepage:
- Size: 22.5 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
[](https://github.com/bep/goportabletext/actions?query=workflow:Test)
[](https://goreportcard.com/report/github.com/bep/goportabletext)
[](https://godoc.org/github.com/bep/goportabletext)
Converts [Portable Text](https://www.portabletext.org/) to Markdown.
## Types supported
* `block` and `span`
* `image`. Note that the image handling is currently very simple; we link to the `asset.url` using `asset.altText` as the image alt text and `asset.title` as the title.
* `code` (see the [code-input](https://www.sanity.io/plugins/code-input) plugin). Code will be rendered as [fenced code blocks](https://gohugo.io/contribute/documentation/#fenced-code-blocks) with any filename provided passed on as a markdown attribute.