code: def replace(self, pattern: str, repl: str):
      self.js_code = re.sub(pattern, repl, self.js_code)
      return self
  
file_path: pyecharts/pyecharts/commons/utils.py
imports: import re
  from ..datasets import EXTRA, FILENAMES
label_desc: Use image node_id 2 for calling the JsCode obj's underlying member method code with example usage: obj.replace(pattern, repl) and returns: self