Skip to content

Commit b635e40

Browse files
committed
small chamges
1 parent 92bf7ff commit b635e40

File tree

1 file changed

+0
-27
lines changed

1 file changed

+0
-27
lines changed

docs/advanced-features.html

Lines changed: 0 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -257,33 +257,6 @@ <h3>Cross-Origin Requests</h3>
257257
</code></pre>
258258
</div>
259259

260-
<div class="feature-card">
261-
<h3>Safe DOM Manipulation</h3>
262-
<p>Use CodeTweak's Trusted Types helpers for safe HTML manipulation:</p>
263-
264-
<pre><code class="language-javascript">// Instead of direct innerHTML assignment (may violate CSP)
265-
// element.innerHTML = '&lt;div&gt;Content&lt;/div&gt;';
266-
267-
// Use CodeTweak's safe helpers
268-
GM_setInnerHTML(element, '&lt;div&gt;Content&lt;/div&gt;');
269-
270-
// Or create trusted HTML
271-
const trustedHTML = GM_createHTML('&lt;div&gt;Content&lt;/div&gt;');
272-
element.innerHTML = trustedHTML;
273-
</code></pre>
274-
275-
<div class="alert alert-warning">
276-
<svg class="icon" viewBox="0 0 24 24">
277-
<path d="M10.29 3.86L1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0z"/>
278-
<line x1="12" y1="9" x2="12" y2="13"/>
279-
<line x1="12" y1="17" x2="12.01" y2="17"/>
280-
</svg>
281-
<div>
282-
<strong>CSP Compliance:</strong> Always use GM_setInnerHTML instead of direct innerHTML assignment on modern websites.
283-
</div>
284-
</div>
285-
</div>
286-
287260
<h2>Debugging & Development</h2>
288261

289262
<div class="feature-card">

0 commit comments

Comments
 (0)