-
Notifications
You must be signed in to change notification settings - Fork 27
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
(add) Option to format readable HTML #134
Comments
As far as I know, there's no such option in Earmark. Even Floki, which is a HTML parser used internally by Serum, does not have one. Still, I would like to have this feature in Serum one day, by implementing HTML pretty formatter on my own (if necessary 😅). EDIT: I forgot to mention that there's currently no HTML pretty formatter package on Hex either... That's why I said I'd implement it on my own if necessary. 🤣 |
In the meantime, I'm sad to say this, you might want to temporarily rely on an external program and optionally a shell script for automation. |
here's my tidy!=(which tidy5 || which tidy)
update-static:
rm -rf site/
env TZ=UTC MIX_ENV=prod mix serum.build
$(tidy) -config tidy.config site/*.html || true
$(tidy) -config tidy.config site/thoughts/*.html || true with the following tidy.config: indent: auto
indent-spaces: 4
tidy-mark: no
punctuation-wrap: yes
vertical-space: yes
wrap: 111
quiet: yes
write-back: yes i'm happy with this solution, and will close this issue for now. |
Thank you for the update! And I'm also sorry for not being able to actively develop/maintain this project for the moment. 🙏 |
no worries, it works well enough without active development! |
Just noticed that Floki v0.30.0 introduced a new option called |
I like to have produce readable HTML on my site.
Is there an option i can pass to Serum / Earmark to do that?
The text was updated successfully, but these errors were encountered: