Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: update website #9

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion website/_includes/base.html
Original file line number Diff line number Diff line change
@@ -1,8 +1,16 @@
<!doctype html>
<html lang="en">
<html lang="en" prefix="og: http://ogp.me/ns#">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta name="twitter:card" content="summary" />
<meta property="twitter:domain" content="bloomberg.github.io" />
<meta property="og:url" content="https://bloomberg.github.io/ts-blank-space" />
<meta property="og:title" content="ts-blank-space" />
<meta
property="og:description"
content="A small, fast, pure JavaScript type-stripper that uses the official TypeScript parser."
/>
<title>{{ title }}</title>
<link rel="stylesheet" href="/node_modules/prism-themes/themes/prism-vs.min.css" />
<link
Expand All @@ -13,6 +21,9 @@
/>
<link rel="stylesheet" href="/assets/base.min.css" />
<style>
html {
font-size: 18px;
}
body {
display: grid;
grid-template-columns: 1fr min(45rem, 90%) 1fr;
Expand Down
4 changes: 2 additions & 2 deletions website/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ var Cat = /** @class */ (function () {
throw Error();
```

That's because TypeScript is performing "down-leveling" to convert your modern JavaScript into something that can run on older JavaScript engines. Because this moves the code around, error stacks and breakpoint locations which not match; so sourcemaps are also generated to correct for this.
That's because TypeScript is performing "down-leveling" to convert your modern JavaScript into something that can run on older JavaScript engines. Because this moves the code around, error stacks and breakpoint locations will not match; so sourcemaps are also generated to correct for this.

Let's try disabling down-leveling using the `tsconfig.json` option `target: "esnext"`:

Expand Down Expand Up @@ -151,7 +151,7 @@ es/error-stack.js n=100000 method="sourcemap": 55,918.729592805634

### Resilience

Bloomberg is a heavy user of sourcemaps, and we have some engineering who are helping to [make them even better.](https://ecma-international.org/news/ecma-tc39-ecmascript-initiates-a-new-task-group-to-standardize-source-maps/) For sourcemaps to work, many different tools must align perfectly align end-to-end. This can lead to them [sometimes failing](https://x.com/robpalmer2/status/1583581325289656320). With `ts-blank-space` your debugging experience will be based on accurate locations even if your environment is misconfigured or you find yourself in situations when sourcemaps would have been inaccessible.
Bloomberg is a heavy user of sourcemaps, and we have some engineers who are helping to [make them even better.](https://ecma-international.org/news/ecma-tc39-ecmascript-initiates-a-new-task-group-to-standardize-source-maps/) For sourcemaps to work, many different tools must perfectly align end-to-end. This can lead to them [sometimes failing](https://x.com/robpalmer2/status/1583581325289656320). With `ts-blank-space` your debugging experience will be based on accurate locations even if your environment is misconfigured or you find yourself in situations when sourcemaps would have been inaccessible.

## Maintenance Benefits

Expand Down
3 changes: 3 additions & 0 deletions website/play/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@
<!-- play.css generated by build -->
<link rel="stylesheet" href="./play.css" />
<style>
html {
font-size: 18px;
}
.tsbs-wrapper {
display: grid;
grid-template-columns: 1fr 1fr;
Expand Down