blueswen / mkdocs-swagger-ui-tag

A MkDocs plugin supports adding Swagger UI to the page.
https://blueswen.github.io/mkdocs-swagger-ui-tag/
MIT License
75 stars 7 forks source link

Generate iframe ids deterministically instead of randomly #20

Closed oprypin closed 6 months ago

oprypin commented 6 months ago

Use the hash of the final HTML content as the frame id.

This will have the benefit of not overwriting all frames with different content and different file names every time the site is built.

+Refactor to not repeat the template generation code twice.

codecov-commenter commented 6 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (663400d) 100.00% compared to head (b2b5eec) 99.34%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #20 +/- ## =========================================== - Coverage 100.00% 99.34% -0.66% =========================================== Files 1 1 Lines 162 153 -9 =========================================== - Hits 162 152 -10 - Misses 0 1 +1 ``` | [Flag](https://app.codecov.io/gh/blueswen/mkdocs-swagger-ui-tag/pull/20/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Blueswen) | Coverage Δ | | |---|---|---| | [unittests](https://app.codecov.io/gh/blueswen/mkdocs-swagger-ui-tag/pull/20/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Blueswen) | `99.34% <100.00%> (-0.66%)` | :arrow_down: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Blueswen#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

blueswen commented 6 months ago

LGTM! Thanks for helping.