Convert embind/emval to JS library format.