<!-- demo.html -->
<!DOCTYPE html>
<html lang="en-US">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Demo</title>
</head>
<body>
<script type="module">
const supportedFormats =
await globalThis.BarcodeDetector?.getSupportedFormats() ?? [];
if (!supportedFormats.includes("qr_code")) {
document.body.innerHTML +=
'<p><a \
href="https://developer.mozilla.org/en-US/docs/Web/API/BarcodeDetector">QR Code detection</a> is not natively supported by your web browser. š</p>';
}
</script>
</body>
</html>
<html>
<body>
<script>
/* some multi-line comment
with function below it */
someFunc();
</script>
</body>
</html>
Also, would it be possible to use u16 as a return type, instead of usize so cast like this: typescript_config_builder.file_indent_level(hints.indent_level.try_into().unwrap_or(0)); is not necessary?
Hints::indent_level
added in https://github.com/g-plane/markup_fmt/pull/86 appears to always be 0.I tried to use it in https://github.com/denoland/deno/pull/27164, but for following 2 files I always get value of 0:
Also, would it be possible to use
u16
as a return type, instead ofusize
so cast like this:typescript_config_builder.file_indent_level(hints.indent_level.try_into().unwrap_or(0));
is not necessary?