Skip to content

Commit 1bb30c7

Browse files
JeanMecheAndrewKushnir
authored andcommitted
docs(docs-infra): remove dependency on html-entities (angular#63416)
HTML entities are now supported, we don't need to convert them. PR Close angular#63416
1 parent eee3e5a commit 1bb30c7

14 files changed

Lines changed: 82 additions & 97 deletions

File tree

MODULE.bazel.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

adev/package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@
4545
"diff": "8.0.2",
4646
"emoji-regex": "10.4.0",
4747
"fflate": "0.8.2",
48-
"html-entities": "2.6.0",
4948
"jasmine-core": "5.9.0",
5049
"jsdom": "26.1.0",
5150
"karma-chrome-launcher": "3.2.0",

adev/shared-docs/package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
"diff": "~8.0.0",
1919
"emoji-regex": "~10.4.0",
2020
"fflate": "^0.8.2",
21-
"html-entities": "~2.6.0",
2221
"jsdom": "~26.1.0",
2322
"marked": "~16.2.0",
2423
"mermaid": "^11.0.0",

adev/shared-docs/pipeline/shared/marked/BUILD.bazel

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ ts_project(
1313
"//adev:node_modules/@types/node",
1414
"//adev:node_modules/diff",
1515
"//adev:node_modules/emoji-regex",
16-
"//adev:node_modules/html-entities",
1716
"//adev:node_modules/jsdom",
1817
"//adev:node_modules/marked",
1918
"//adev:node_modules/mermaid",

adev/shared-docs/pipeline/shared/marked/extensions/docs-code/format/highlight.mts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
* found in the LICENSE file at https://angular.dev/license
77
*/
88

9-
import {decode} from 'html-entities';
109
import {CodeToken} from './index.mjs';
1110
import {expandRangeStringValues} from './range.mjs';
1211
import {JSDOM} from 'jsdom';
@@ -25,10 +24,9 @@ export function highlightCode(highlighter: HighlighterGeneric<any, any>, token:
2524
// TODO(josephperrott): Handle mermaid usages i.e. language == mermaidClassName
2625
if (token.language !== 'none' && token.language !== 'file') {
2726
// Decode the code content to replace HTML entities to characters
28-
const decodedCode = decode(token.code);
2927
const language = token.language ?? guessLanguageFromPath(token.path);
3028

31-
const codeAsHtml = codeToHtml(highlighter, decodedCode, language);
29+
const codeAsHtml = codeToHtml(highlighter, token.code, language);
3230
token.code = codeAsHtml;
3331
}
3432

adev/src/content/cli/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ Install the CLI using the `npm` package manager:
1010

1111
<code-example format="shell" language="shell">
1212

13-
npm install -g &commat;angular/cli<aio-angular-dist-tag class="pln"></aio-angular-dist-tag>
13+
npm install -g @angular/cli<aio-angular-dist-tag class="pln"></aio-angular-dist-tag>
1414

1515
</code-example>
1616

adev/src/content/ecosystem/service-workers/getting-started.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ npm, which supports service worker applications. Run it without installation usi
5050

5151
<docs-code language="shell">
5252

53-
npx http-server -p 8080 -c-1 dist/&lt;project-name&gt;/browser
53+
npx http-server -p 8080 -c-1 dist/<project-name>/browser
5454

5555
</docs-code>
5656

adev/src/content/guide/di/hierarchical-dependency-injection.md

Lines changed: 71 additions & 71 deletions
Large diffs are not rendered by default.

adev/src/content/guide/testing/components-scenarios.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -307,7 +307,7 @@ If you use the Angular CLI, configure this flag in `src/test.ts`.
307307

308308
<docs-code language="typescript">
309309

310-
[window as any]('&lowbar;&lowbar;zone&lowbar;symbol__fakeAsyncPatchLock') = true;
310+
[window as any]('__zone_symbol__fakeAsyncPatchLock') = true;
311311
import 'zone.js/testing';
312312

313313
</docs-code>

adev/src/content/reference/versions.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -146,14 +146,14 @@ For example:
146146
* asynchronous activities to improve startup performance - use these options only
147147
* if you know what you are doing as it could result in hard to trace down bugs.
148148
*/
149-
// &lowbar;&lowbar;Zone_disable_requestAnimationFrame = true; // disable patch requestAnimationFrame
150-
// &lowbar;&lowbar;Zone_disable_on_property = true; // disable patch onProperty such as onclick
151-
// &lowbar;&lowbar;zone_symbol__UNPATCHED_EVENTS = ['scroll', 'mousemove']; // disable patch specified eventNames
149+
// __Zone_disable_requestAnimationFrame = true; // disable patch requestAnimationFrame
150+
// __Zone_disable_on_property = true; // disable patch onProperty such as onclick
151+
// __zone_symbol__UNPATCHED_EVENTS = ['scroll', 'mousemove']; // disable patch specified eventNames
152152
/*
153153
* in Edge developer tools, the addEventListener will also be wrapped by zone.js
154154
* with the following flag, it will bypass `zone.js` patch for Edge.
155155
*/
156-
// &lowbar;&lowbar;Zone_enable_cross_context_check = true;
156+
// __Zone_enable_cross_context_check = true;
157157
</script>
158158
<!-- zone.js required by Angular -->
159159
<script src="node_modules/zone.js/bundles/zone.umd.js"></script>

0 commit comments

Comments
 (0)