Issues rendering state diagrams for any machines that renders → on windows machine#2
Open
ank634 wants to merge 3 commits intoDaymudeLab:mainfrom
Open
Issues rendering state diagrams for any machines that renders → on windows machine#2ank634 wants to merge 3 commits intoDaymudeLab:mainfrom
ank634 wants to merge 3 commits intoDaymudeLab:mainfrom
Conversation
…-8 so windows machines which dont always use utf-8 by default can have acces to the right arrow character when displaying state diagrams for pdas
Author
|
See the source code for the render-html fork |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Currently when a windows machine wants to display a state diagram that has the → character there is an error

The reason for this issue lies in the library render-html. render-html does relies on writing and opening a file when rendering it. render-html does not have an interface to select the encoding so the default one for each operating system is chosen. It just so happens to be that windows default is not utf-8 and the windows default encoding does not support the → by default, causing this error. linux and mac os have utf-8 encoding by default so this error does not arise for those operating system.
Proposed solution
To fix this I have forked render-html and published a package that has kept the interface the same except added an optional parameter for encoding. I have updated the project to use this new package and edited the source code to pass utf-8 encoding when rendering the html. This has fixed the problem.