You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The binding is implemented as a C-Node following the excellent example in Overbryd's package nodex. If you want to learn how to set up bindings to C/C++, you should definitely check it out.
C-Nodes are external os-processes that communicate with the Erlang VM through erlang messaging. That way you can implement native code and call into it from Elixir in a safe predictable way. The Erlang VM stays unaffected by crashes of the external process.
test"can parse broken html"doresult=TidyEx.parse("<div>Hello<span>World")assertresult=="<div>Hello<span>World</span></div>"endtest"can clean and repair broken html"doresult=TidyEx.clean_and_repair("<div>Hello<span>World")assertresult=="<div>Hello<span>World</span></div>"endtest"can run diagnostics on invalid html"doresult=TidyEx.run_diagnostics("<pp>Hello World</p>")assertresult=="line 1 column 1 - Error: <pp> is not recognized!\nThis document has errors that must be fixed before\nusing HTML Tidy to generate a tidied up version."end