Skip to content

Commit

Permalink
feat(@ngtools/webpack): allow .svg files as templates
Browse files Browse the repository at this point in the history
With directTemplateLoading enabled, components
can now use .svg files as templates. For AOT builds,
the Angular compiler host now reads .svg files
directly when reading component templates.
For JIT builds, replaceResources creates a require call
that directly uses raw-loader instead of using the
loader provided by the current webpack configuration.

Closes angular#10567
  • Loading branch information
oocx committed Feb 24, 2019
2 parents f1e092b + 58bc5b8 commit 18e5d2d
Show file tree
Hide file tree
Showing 503 changed files with 8,941 additions and 4,667 deletions.
2 changes: 1 addition & 1 deletion .appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ install:
- ps: Install-Product node $env:nodejs_version
# --network-timeout is a workaround for https://github.com/yarnpkg/yarn/issues/6221
- yarn --frozen-lockfile --network-timeout=500000
- yarn webdriver-update-appveyor
- yarn webdriver-update

test_script:
- node --version
Expand Down
32 changes: 32 additions & 0 deletions .buildkite/pipeline.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
steps:
- label: windows-test
commands:
# Yarn workspaces creates directory junctions inside node_modules, but these fail in docker.
# E.g. inside the container, `mklink /J "C:\src\_" "C:\src\packages\_"` will fail with
# `Access is denied.`
# https://github.com/moby/moby/issues/37024
# As a workaround, we copy all files in the shared volume and run the commands in the new dir.
- xcopy C:\workdir C:\workdir-copy /E /H /K /S /Q /I
- cd C:\workdir-copy
# Actual CI commands
# --network-timeout is a workaround for https://github.com/yarnpkg/yarn/issues/6221
- yarn install --frozen-lockfile --non-interactive --network-timeout 500000
- yarn webdriver-update
- node --version
- yarn --version
- yarn test
# Move this file into the .buildkite folder if Appveyor is removed.
- appveyor-e2e.bat
# - bazel test ...
plugins:
- docker#v2.1.0:
image: "filipesilva/node-bazel-windows:0.0.2"
# Times out in 2h
timeout_in_minutes: 120
# Automatically retries up to 2 times.
retry:
automatic:
exit_status: "*"
limit: 2
agents:
windows: true
18 changes: 17 additions & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ jobs:
parallelism: 4
steps:
- attach_workspace: *attach_options
- run: npm run webdriver-update-circleci
- run: npm run webdriver-update
- run: npm run test-large -- --full --nb-shards=${CIRCLE_NODE_TOTAL} --shard=${CIRCLE_NODE_INDEX}

e2e-cli:
Expand Down Expand Up @@ -114,6 +114,16 @@ jobs:
- attach_workspace: *attach_options
- run: xvfb-run -a node ./tests/legacy-cli/run_e2e --nb-shards=${CIRCLE_NODE_TOTAL} --shard=${CIRCLE_NODE_INDEX} --ng-snapshots

e2e-cli-ivy-snapshots:
<<: *defaults
environment:
BASH_ENV: ~/.profile
resource_class: xlarge
parallelism: 4
steps:
- attach_workspace: *attach_options
- run: xvfb-run -a node ./tests/legacy-cli/run_e2e --nb-shards=${CIRCLE_NODE_TOTAL} --shard=${CIRCLE_NODE_INDEX} --ng-snapshots --ivy

build:
<<: *defaults
steps:
Expand Down Expand Up @@ -200,6 +210,12 @@ workflows:
filters:
branches:
only: master
- e2e-cli-ivy-snapshots:
requires:
- build
filters:
branches:
only: master
- snapshot_publish:
requires:
- test
Expand Down
58 changes: 6 additions & 52 deletions .github/ISSUE_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -1,56 +1,10 @@
<!--
IF YOU DON'T FILL OUT THE FOLLOWING INFORMATION YOUR ISSUE MIGHT BE CLOSED WITHOUT INVESTIGATING
-->
### Bug Report or Feature Request (mark with an `x`)
```
- [ ] bug report -> please search issues before submitting
- [ ] feature request
```
🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑

### Command (mark with an `x`)
```
- [ ] new
- [ ] build
- [ ] serve
- [ ] test
- [ ] e2e
- [ ] generate
- [ ] add
- [ ] update
- [ ] lint
- [ ] xi18n
- [ ] run
- [ ] config
- [ ] help
- [ ] version
- [ ] doc
```
Please help us process issues more efficiently by filing an
issue using one of the following templates:

### Versions
<!--
Output from: `node --version`, `npm --version` and `ng --version`.
Windows (7/8/10). Linux (incl. distribution). macOS (El Capitan? Sierra? High Sierra?)
-->
https://github.com/angular/angular-cli/issues/new/choose

Thank you!

### Repro steps
<!--
Simple steps to reproduce this bug.
Please include: commands run (incl args), packages added, related code changes.
A link to a sample repo would help too.
-->


### The log given by the failure
<!-- Normally this include a stack trace and some more information. -->


### Desired functionality
<!--
What would like to see implemented?
What is the usecase?
-->


### Mention any other details that might be useful
<!-- Please include a link to the repo if this is related to an OSS project. -->
🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑
80 changes: 80 additions & 0 deletions .github/ISSUE_TEMPLATE/1-bug-report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
---
name: "\U0001F41EBug report"
about: Report a bug in Angular CLI
---
<!--🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅
Oh hi there! 😄
To expedite issue processing please search open and closed issues before submitting a new one.
Existing issues often contain information about workarounds, resolution, or progress updates.
🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅-->


# 🐞 Bug report

### Command (mark with an `x`)
<!-- Can you pin-point the command or commands that are effected by this bug? -->
<!-- ✍️edit: -->
```
- [ ] new
- [ ] build
- [ ] serve
- [ ] test
- [ ] e2e
- [ ] generate
- [ ] add
- [ ] update
- [ ] lint
- [ ] xi18n
- [ ] run
- [ ] config
- [ ] help
- [ ] version
- [ ] doc
```

### Is this a regression?

<!-- Did this behavior use to work in the previous version? -->
<!-- ✍️--> Yes, the previous version in which this bug was not present was: ....


### Description

<!-- ✍️--> A clear and concise description of the problem...


## 🔬 Minimal Reproduction
<!--
Simple steps to reproduce this bug.
Please include: commands run (including args), packages added, related code changes.
If reproduction steps are not enough for reproduction of your issue, please create a minimal GitHub repository with the reproduction of the issue. Share the link to the repo below along with step-by-step instructions to reproduce the problem, as well as expected and actual behavior.
Issues that don't have enough info and can't be reproduced will be closed.
You can read more about issue submission guidelines here: https://github.com/angular/angular-cli/blob/master/CONTRIBUTING.md#-submitting-an-issue
-->

## 🔥 Exception or Error
<pre><code>
<!-- If the issue is accompanied by an exception or an error, please share it below: -->
<!-- ✍️-->

</code></pre>


## 🌍 Your Environment
<pre><code>
<!-- run `ng version` and paste output below -->
<!-- ✍️-->

</code></pre>

**Anything else relevant?**
<!-- ✍️Is this a browser specific issue? If so, please specify the browser and version. -->

<!-- ✍️Do any of these matter: operating system, IDE, package manager, HTTP server, ...? If so, please mention it below. -->
49 changes: 49 additions & 0 deletions .github/ISSUE_TEMPLATE/2-feature-request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
---
name: "\U0001F680Feature request"
about: Suggest a feature for Angular CLI

---
<!--🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅
Oh hi there! 😄
To expedite issue processing please search open and closed issues before submitting a new one.
Existing issues often contain information about workarounds, resolution, or progress updates.
🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅-->


# 🚀 Feature request


### Command (mark with an `x`)
<!-- Can you pin-point the command or commands that are relevant for this feature request? -->
<!-- ✍️edit: -->
```
- [ ] new
- [ ] build
- [ ] serve
- [ ] test
- [ ] e2e
- [ ] generate
- [ ] add
- [ ] update
- [ ] lint
- [ ] xi18n
- [ ] run
- [ ] config
- [ ] help
- [ ] version
- [ ] doc
```

### Description
<!-- ✍️--> A clear and concise description of the problem or missing capability...


### Describe the solution you'd like
<!-- ✍️--> If you have a solution in mind, please describe it.


### Describe alternatives you've considered
<!-- ✍️--> Have you considered any alternative solutions or workarounds?
13 changes: 13 additions & 0 deletions .github/ISSUE_TEMPLATE/3-docs-bug.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
---
name: "📚 Docs or angular.io issue report"
about: Report an issue in Angular's documentation or angular.io application

---

🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑

Please file any Docs or angular.io issues at: https://github.com/angular/angular/issues/new/choose

For the time being, we keep Angular AIO issues in a separate repository.

🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑
11 changes: 11 additions & 0 deletions .github/ISSUE_TEMPLATE/4-security-issue-disclosure.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
name: ⚠️Security issue disclosure
about: Report a security issue in Angular Framework, Material, or CLI

---

🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑

Please read https://angular.io/guide/security#report-issues on how to disclose security related issues.

🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑
16 changes: 16 additions & 0 deletions .github/ISSUE_TEMPLATE/5-support-request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
name: "❓Support request"
about: Questions and requests for support

---

🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑

Please do not file questions or support requests on the GitHub issues tracker.

You can get your questions answered using other communication channels. Please see:
https://github.com/angular/angular-cli/blob/master/CONTRIBUTING.md#question

Thank you!

🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑
13 changes: 13 additions & 0 deletions .github/ISSUE_TEMPLATE/6-angular-framework.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
---
name: "⚡Angular Framework"
about: Issues and feature requests for Angular Framework

---

🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑

Please file any Angular Framework issues at: https://github.com/angular/angular/issues/new/choose

For the time being, we keep Angular issues in a separate repository.

🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑
13 changes: 13 additions & 0 deletions .github/ISSUE_TEMPLATE/7-angular-material.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
---
name: "\U0001F48EAngular Material"
about: Issues and feature requests for Angular Material

---

🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑

Please file any Angular Material issues at: https://github.com/angular/material2/issues/new

For the time being, we keep Angular Material issues in a separate repository.

🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑🛑
2 changes: 2 additions & 0 deletions .mailmap
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ Charles Lyding <clydin@users.noreply.github.com>
Charles Lyding <clydin@users.noreply.github.com> <19598772+clydin@users.noreply.github.com>
Filipe Silva <filipematossilva@gmail.com>
Mike Brocchi <mbrocchi@gmail.com>
Alan Agius <alan.agius4@users.noreply.github.com>
Alan Agius <alan.agius4@users.noreply.github.com> <alan.agius4@gmail.com> <alan.agius@betssongroup.com>


################################################################################
Expand Down
Loading

0 comments on commit 18e5d2d

Please sign in to comment.