def staticfy(html_file, args=argparse.ArgumentParser()):
<EOL>static_endpoint = args.static_endpoint or '<STR_LIT>'<EOL>framework = args.framework or os.getenv('<STR_LIT>', '<STR_LIT>')<EOL>add_tags = args.add_tags or {}<EOL>exc_tags = args.exc_tags or {}<EOL>namespace = args.namespace or {}<EOL>tags = {('<STR_LIT>', '<STR_LIT:src>'), ('<STR_LIT>', '<STR_LIT>'), ('<STR_LIT>', '<STR_LIT:src>')}<EOL>add_tags = {(tag, attr) for tag, attr in add_tags.items()}<EOL>tags.update(add_tags)<EOL>exc_tags = {(tag, attr) for tag, attr in exc_tags.items()}<EOL>tags = tags - exc_tags<EOL>matches = get_elements(html_file, tags)<EOL>transformed = transform(matches, framework, namespace, static_endpoint)<EOL>return replace_lines(html_file, transformed)<EOL>
Staticfy method.

Loop through each line of the file and replaces the old links