mirror of
https://github.com/simonw/datasette.git
synced 2026-06-08 18:16:59 +02:00
?_trac=1 for CSV, plus ?_nofacets=1 when rendering CSV
Closes #1351, closes #1350
This commit is contained in:
parent
c5ae1197a2
commit
d1d06ace49
3 changed files with 64 additions and 7 deletions
|
|
@ -7,6 +7,7 @@ import hashlib
|
|||
import inspect
|
||||
import itertools
|
||||
import json
|
||||
import markupsafe
|
||||
import mergedeep
|
||||
import os
|
||||
import re
|
||||
|
|
@ -777,6 +778,14 @@ class LimitedWriter:
|
|||
await self.writer.write(bytes)
|
||||
|
||||
|
||||
class EscapeHtmlWriter:
|
||||
def __init__(self, writer):
|
||||
self.writer = writer
|
||||
|
||||
async def write(self, content):
|
||||
await self.writer.write(markupsafe.escape(content))
|
||||
|
||||
|
||||
_infinities = {float("inf"), float("-inf")}
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue