def escapejs(value):
    for bad, good in JS_ESCAPES:
        value = value.replace(bad, good)
    return value
Hex encodes characters for use in JavaScript strings.
dataset/ETHPy150Open anandology/pyjamas/pyjs/src/pyjs/translator_proto.py/escapejs