Commit graph

43 commits

Author SHA1 Message Date
Ward Bell
a28864d0f7 docs: migrate template guide and its code examples to standalone. (#51364)
Guide pages do not mention `NgModule` so they are untouched (and not "reviewed" either).

All code was migrated, including code in the `template-expression-operators` folder despite it only being referenced in the “archived” guide, `template-expression-operators.md`.

PR Close #51364
2023-08-28 18:36:51 +00:00
Angular Robot
27d43a4a7f build: lock file maintenance (#51134)
See associated pull request for more information.

PR Close #51134
2023-07-24 08:12:51 -07:00
alkavats1
5dc7a99393 docs: added the alt attribute to the imag tag and replaced the i tag with the em tag (#50570)
PR Close #50570
2023-06-14 15:28:22 +02:00
Angular Robot
7ca301acd5 build: update dependency eslint-plugin-jsdoc to v45 (#50523)
See associated pull request for more information.

PR Close #50523
2023-05-31 12:34:26 -07:00
Matthieu Riegler
82c8b7ae9e build(docs-infra): replace base64 images for stackblitz by svgs (#48774)
PNG converted to base64 don't work on stackblitz.
As stackblitz does't support binary files for dynamicaly created projects, we now use only svgs.

Fixes: #48773

PR Close #48774
2023-01-24 16:39:28 +00:00
Derek Cormier
9a27c4cb50 build(bazel): incrementally build aio example zips and live examples
The existing scripts were amended to work on one example at a time
2022-11-22 13:51:16 -07:00
Alan Agius
32135b27a1 docs: update examples to reflect changes in Angular CLI version 15. (#47904)
These changes include
- Remove the usage of `enableProdMode`
- Remove `test.ts`, `polyfills.ts`, `karma.conf.js` and environment files which are no longer generated by default

PR Close #47904
2022-11-03 17:46:46 -07:00
Bob Watson
274c6fa643 docs: remove Narco from hero list in code, text, and images (#46008)
Fixes issue #45769

Removes the malevolent comic book character, "Narco," from the list of heroes. This change removes the reference from the code, text and screenshots used in the documentation and makes other minor edits as necessary.

PR Close #46008
2022-05-17 17:47:03 +00:00
dario-piotrowicz
0d19be1996 refactor(docs-infra): add types to all the aio examples buttons (#44557)
add types to all the buttons in the angular.io examples to encourage
the best practice of always including a type per button (regardless
to whether it is in a form or now)

PR Close #44557
2022-02-03 12:44:47 -08:00
Dario Piotrowicz
5498a35789 refactor(docs-infra): fix template eslint issues in aio examples (#44557)
the aio examples have various eslint issues regarding template rules, those
are currently turned off and TODO comments have been added to them in the
examples eslintrc, fix such issues and remove the respective TODO comments

this also includes examples refactoring to use buttons for better accessibility,
this change tries to make the smallest amound of changes to the examples' behaviors
and designs/UI

PR Close #44557
2022-02-03 12:44:46 -08:00
dario-piotrowicz
835987b78b refactor(docs-infra): use eslint in aio's example-lint script (#43218)
Instead of the deprecated tslint use eslint in the aio's example-lint
script

PR Close #43218
2021-12-15 12:28:46 -05:00
George Kalpakas
7b35a3426f refactor(docs-infra): align docs examples with default CLI TS config (#43880)
This commit enable the `noImplicitOverride` and
`noPropertyAccessFromIndexSignature` TypeScript compiler options for
docs examples to better align with the default configuration of new
Angular CLI apps. It also makes the necessary changes to the docs
examples source code.

PR Close #43880
2021-10-29 13:10:25 -07:00
markostanimirovic
018af62141 docs: fix forms in template examples (#43772)
PR Close #43772
2021-10-08 20:39:11 +00:00
Andrew Scott
d04b550f2e docs: Deprecate longhand binding prefixes (#43671)
DEPRECATION:

The template prefixes `bind-`, `on-`, `bindon-`, and `ref-` have been deprecated
in v13. Templates should use the more widely documented syntaxes for binding and references:

* `[input]="value"` instead of `bind-input="value"`
* `[@trigger]="value"` instead of `bind-animate-trigger="value"`
* `(click)="onClick()"` instead of `on-click="onClick()"`
* `[(ngModel)]="value"` instead of `bindon-ngModel="value"`
* `#templateRef` instead of `ref-templateRef`

PR Close #43671
2021-10-04 10:27:06 -07:00
Kristiyan Kostadinov
e86a1d3441 docs: make all examples compatible with strict mode (#41999)
Turns on the `strict` compiler flag and resolves the compilation errors in the various AIO examples.

PR Close #41999
2021-05-17 10:42:18 -07:00
Pete Bacon Darwin
4859c0947a build(docs-infra): implement full template checking for examples (#40930)
This commit turns on full template type checking and fixes the examples
that had errors.

PR Close #40930
2021-02-26 15:40:44 -08:00
Pete Bacon Darwin
4a9f7daf37 docs: remove unused "docregions" (#40479)
This commit removes all the docregion tags in examples that are not
being referenced in any doc.

PR Close #40479
2021-01-20 16:12:15 -08:00
Alexey Elin
f846c093b1 docs: specify fallback generic font family (#40254)
https://developer.mozilla.org/en-US/docs/Web/CSS/font-family
"You should always include at least one generic family name in a font-family list,
 since there's no guarantee that any given font is available. This lets the browser
 select an acceptable fallback font when necessary."

PR Close #40254
2021-01-06 07:09:27 -08:00
George Kalpakas
23c36a24ed test(docs-infra): disable the Selenium Promise Manager in docs examples e2e tests (#39818)
This commit disables the Selenium Promise Manager when running e2e tests
for docs examples in order to more closely align them with new apps
created with CLI v11. This change requires that any async operations in
tests are handled explicitly (e.g. using `async/await` or
`Promise#then()`).

PR Close #39818
2020-11-24 14:56:14 -08:00
Marcono1234
3e1e5a15ba docs: update links to use HTTPS as protocol (#39718)
PR Close #39718
2020-11-20 12:52:16 -08:00
George Kalpakas
0a791e4a50 style(docs-infra): fix docs examples for tslint rule import-spacing (#38143)
This commit updates the docs examples to be compatible with the
`import-spacing` tslint rule.

This is in preparation of updating the docs examples `tslint.json` to
match the one generated for new Angular CLI apps in a future commit.

PR Close #38143
2020-07-31 11:00:05 -07:00
George Kalpakas
d89200ad24 refactor(docs-infra): remove unnecessary use strict from docs examples TS files (#38143)
By default, TypeScript will emit `"use strict"` directives, so it is not
necessary to include `'use strict'` in `.ts` files:
https://www.typescriptlang.org/docs/handbook/compiler-options.html#:~:text=--noImplicitUseStrict

PR Close #38143
2020-07-31 11:00:05 -07:00
crisbeto
9d54679e66 test: clean up explicit dynamic query usages (#33015)
Cleans up all the places where we explicitly set `static: false` on queries.

PR Close #33015
2019-10-17 16:10:10 -04:00
Michael Prentice
09970d52e8 docs(core): in template syntax guide, make SVG example more clear (#31356)
add e2e test for SVG template example
fix template syntax example app
- linting errors
- runtime exceptions
- template type errors
- deprecated type casting
- deprecated currency pipe example

Relates to #30559

PR Close #31356
2019-07-02 11:30:15 -07:00
Santosh Yadav
c6b29f4c6d docs: added svg example (#30559)
Fixes #30441

PR Close #30559
2019-06-27 15:56:26 -07:00
Alex Rickabaugh
84dd2679a9 fix(core): require 'static' flag on queries in typings (#30639)
This commit makes the static flag on @ViewChild and @ContentChild required.

BREAKING CHANGE:

In Angular version 8, it's required that all @ViewChild and @ContentChild
queries have a 'static' flag specifying whether the query is 'static' or
'dynamic'. The compiler previously sorted queries automatically, but in
8.0 developers are required to explicitly specify which behavior is wanted.
This is a temporary requirement as part of a migration; see
https://angular.io/guide/static-query-migration for more details.

@ViewChildren and @ContentChildren queries are always dynamic, and so are
unaffected.

PR Close #30639
2019-05-24 16:55:00 -04:00
janith
c79bffaacb docs: remove gender prefixes from examples (#29972)
PR Close #29972
2019-05-20 16:42:59 -07:00
George Kalpakas
282167a37f build(docs-infra): upgrade tslint to 5.15.0 and codelyzer to 5.0.0 (#29926)
This commit also changes the `tslint.json` config file to (reasonably
closely) match what the cli would generate for a new app.

PR Close #29926
2019-04-25 12:32:49 -07:00
Brandon
531aa5f8db docs: make method arguments optional in template syntax example (#28592)
PR Close #28592
2019-02-11 17:09:25 +00:00
Brandon Roberts
2278fe8f0e docs(aio): Upgrade examples to Angular 6 (#23234)
PR Close #23234
2018-04-17 14:09:02 -07:00
Jesus Rodriguez
1a75934cc0 build(aio): migrate plunker to stackblitz (#20165)
PR Close #20165
2018-01-23 21:30:27 -08:00
Chuck Jazdzewski
2d44a2ab0d docs(compiler): document the $any type cast function (#20968)
Closes #20966

PR Close #20968
2018-01-12 14:37:26 -08:00
Jesus Rodriguez
9bbf009dff build(aio): change examples to CLI (#19248)
PR Close #19248
2017-09-21 17:05:54 -07:00
Aravind
867ab11def docs(aio): fix typo 2017-09-12 13:57:44 -04:00
Olivier Combe
56238fe94e feat(compiler): set enableLegacyTemplate to false by default (#18756)
BREAKING CHANGE: the compiler option `enableLegacyTemplate` is now disabled by default as the `<template>` element has been deprecated since v4. Use `<ng-template>` instead. The option `enableLegacyTemplate` and the `<template>` element will both be removed in Angular v6.
PR Close #18756
2017-08-31 18:38:34 -07:00
Victor Berchet
0ede642cb9 docs(aio): Update NgStyle and NgClass to use quoted keys 2017-07-07 16:17:33 -07:00
Georgios Kalpakas
4f37f86433 fix(aio): switch from innerText to textContent to support older browsers
`innerText` is not supported in Firefox prior to v45. In most cases (at least
the ones we are interested in), `innerText` and `textContent` work equally well,
but `textContent` is more performant (as it doesn't require a reflow).

From [MDN][1] on the differences of `innerText` vs `textContent`:

> - [...]
> - `innerText` is aware of style and will not return the text of hidden
>   elements, whereas `textContent` will.
> - As `innerText` is aware of CSS styling, it will trigger a reflow, whereas
>   `textContent` will not.
> - [...]

[1]: https://developer.mozilla.org/en-US/docs/Web/API/Node/textContent#Differences_from_innerText

Fixes #17585
2017-06-19 10:32:36 -07:00
Trotyl Yu
38fc2a0055 fix(aio): fix trackBy demo in template-syntax article 2017-06-14 12:04:59 +01:00
Chuck Jazdzewski
74673545c0 docs(aio): document the non-null assertion operator 2017-06-08 12:55:19 -07:00
Jesús Rodríguez
55b8de9fdd build(aio): lint examples 2017-05-03 13:44:41 -07:00
Jesus Rodriguez
061475402c docs(aio): final migration from old site 2017-04-12 21:01:55 +01:00
Peter Bacon Darwin
fd72fad8fd docs(aio): update migrated content from anguar.io 2017-03-28 10:21:46 +01:00
Peter Bacon Darwin
1f3198cb50 feat(aio): copy example code from angular.io 2017-02-23 23:23:58 -08:00