-
-
Notifications
You must be signed in to change notification settings - Fork 141
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
html/head/body tags should not be added automatically to an existing file/partial #822
Comments
Hi @jarmo, thanks for reporting this use case and sharing your feedback. pwa-asset-generator was not designed to make edits to partial html files. I will mark it as a feature request and consider this improvement as part of the roadmap. |
@onderceylan thank you for your reply. I would like to argue (in a friendly way, of course) that When you think about it then index.html would be 99% of times a valid HTML already when it is an existing file and there's no need to add parent nodes nor create I would either expect it to throw an error when it can't find Since partials are not something esoteric in web application frameworks and current behavior of All in all, thanks for this nice tool, which has helped me to spare some time developing PWAs. |
This feature would simplify everyone's life a lot. Thanks! |
Describe the bug
I used pwa-asset-generator with
--index
flag to automatically add all splash image html tags for iOS. It added these tags as expected. However, it also addedhtml
,head
andbody
tags which was unexpected:Since my "index" file is not an actual index, but is a separate partial html file, which is included by the html templating language I'm using into an actual "index.html"
head
tag then this broke my html and PWA (iOS actually doesn't work properly like this).To Reproduce
Steps to reproduce the behavior:
npx pwa-asset-generator pwa-icon.jpg -i partial-head.html
Expected behavior
pwa-asset-generator should not automatically add/modify any
html
,head
andbody
tags when it is modifying a file instead of creating a new one. Or there should be a way to disable this behavior with an extra flag.Anyway, this behavior was unexpected and unnoticed at first and it broke PWA.
System (please complete the following information):
The text was updated successfully, but these errors were encountered: