Skip to content
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

[HTML2]Html2 api documentation generated by codegen does not render correctly in IE #5780

Closed
leonluocheng opened this issue Jun 5, 2017 · 7 comments

Comments

@leonluocheng
Copy link
Contributor

leonluocheng commented Jun 5, 2017

Description

Html2 client generated by codegen does not render correctly in IE 11. as shows in screenshot, exactly same html2 client but when opened by IE 11, part of the parameter schema are missing. This issue does not happen in chrome, edge and Firefox. Also this issue does not happen when I using swagger online editor to generate the html2 documentation.

image

Swagger-codegen version

master branch 2.3

Swagger declaration file content or url

Example perstore.json

I am looking for a possible solution here. and also this issue does not occur when using swagger online editor tool.

@wing328
Copy link
Contributor

wing328 commented Jun 9, 2017

@leonluocheng thanks for reporting the issue. Swagger Editor is using the latest stable version (v2.2.2).

Seems like the issue was introduced to master after the stable release.

I wonder if you can help perform a "git bisect" with the latest master and 2.2.2 commit to identy which changes broke it.

@leonluocheng
Copy link
Contributor Author

@wing328 hmm, interesting. sure, I can help on this.

@leonluocheng
Copy link
Contributor Author

@wing328 After "git bisect". found out this commitment cause this issue.

image

@leonluocheng
Copy link
Contributor Author

leonluocheng commented Jun 19, 2017

@wing328 I am a js newbie. but after debugging on 5313 . found out that "object.assign" is not support at IE11. looks like we need to find a way to polyfill this issue.

A quick fix is to change "schemaWrapper.definitions = Object.assign({}, defs);" to "schemaWrapper.definitions = defs;"

@wing328
Copy link
Contributor

wing328 commented Jun 21, 2017

@leonluocheng thanks for identifying the issue.

@wy-z would you please take a look when you've time and see if the suggested fix by @leonluocheng works for you?

@wing328
Copy link
Contributor

wing328 commented Dec 16, 2017

A quick fix is to change "schemaWrapper.definitions = Object.assign({}, defs);" to "schemaWrapper.definitions = defs;"

@leonluocheng Please file a PR with the fix when you've time

@wing328 wing328 modified the milestones: v2.3.0, v2.4.0 Dec 16, 2017
@leonluocheng
Copy link
Contributor Author

@wing328 sure np.

leonluocheng added a commit to leonluocheng/swagger-codegen that referenced this issue Jun 14, 2018
HugoMario added a commit that referenced this issue Jun 14, 2018
crumpf added a commit to crumpf/swagger-codegen that referenced this issue Jul 19, 2018
* master:
  Fix issue swagger-api#5780
  Update README.md
  Run /bin scripts
  Call super management for managing imports in postProcessModelProperty
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants