mandolyte / mdtopdf

Markdown to PDF
MIT License
133 stars 32 forks source link

refactor: switch to stdlib slices instead of exp #58

Closed a-h closed 3 months ago

jessp01 commented 3 months ago

Hi @a-h ,

I've no objection to replacing ioutil.ReadAll() with io.ReadAll() since as of Go 1.16, ioutil.ReadAll is deprecated and simply calls io.ReadAll and mdtopdf requires Golang 1.18 and above.

However, slices was only introduced to stdlib in Golang 1.21 (see https://pkg.go.dev/slices?tab=versions) and I don't feel incrementing the minimum required version solely to make use of it is justified. I did, however, update go.mod so it now uses the latest golang.org/x/exp version.

If you'd like to revise your pull accordingly, I'm happy to merge it.

Thanks,