Skip to content

Commit

Permalink
docs: update website (#9)
Browse files Browse the repository at this point in the history
- Adds social media preview headers
- Fix typo in website

---------

Signed-off-by: Ashley Claymore <[email protected]>
  • Loading branch information
acutmore authored Sep 26, 2024
1 parent b85fcb0 commit 3c8f7c5
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 3 deletions.
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

0 comments on commit 3c8f7c5

Please sign in to comment.