JavaScript Restrictor
Browser extension that improves privacy and security
Loading...
Searching...
No Matches
i18n_translate_dom.js File Reference

JS code that retrieves all HTML files with data-localize attributes and localizes them. More...

Functions

function localizeHTMLelement (e)
 
 for (t of templates)
 

Variables

const textElements = document.querySelectorAll('[data-localize]')
 
const templates = document.getElementsByTagName("template")
 

Detailed Description

JS code that retrieves all HTML files with data-localize attributes and localizes them.

Author
Copyright (C) 2022 TotalCaesar659

See https://github.com/polcak/jsrestrictor/pull/189 for the origins of the code.

License:
SPDX-License-Identifier: GPL-3.0-or-later

Function Documentation

◆ for()

for ( t of  templates)
Here is the call graph for this function:

◆ localizeHTMLelement()

function localizeHTMLelement (   e)
Here is the caller graph for this function:

Variable Documentation

◆ templates

const templates = document.getElementsByTagName("template")

◆ textElements

const textElements = document.querySelectorAll('[data-localize]')