Skip to content
This repository was archived by the owner on Apr 4, 2025. It is now read-only.

File replacements work only for TypeScript files #885

Closed
sis0k0 opened this issue May 10, 2018 · 0 comments · Fixed by #887
Closed

File replacements work only for TypeScript files #885

sis0k0 opened this issue May 10, 2018 · 0 comments · Fixed by #887

Comments

@sis0k0
Copy link
Contributor

sis0k0 commented May 10, 2018

Bug Report or Feature Request (mark with an x)

- [ ] bug report -> please search issues before submitting
- [X] feature request

Area

- [X] devkit
- [ ] schematics

Versions

node: v9.9.0
npm: v5.8.0
OS: Fedora 25

Repro steps

https://github.com/sis0k0/ng-webpack-vfs-issue/

Desired functionality

The file replacement functionality should work for all types of files.
Currently, the file replacement functionality works only for TS files. More specifically - it works only for files that are part of the webpack compiler host.
Also, the webpack input filesystem host that's provided as an option of the AngularCompilerPlugin doesn't intercept any requests to html and css files or external packages, which contain JS (not TS) files.

Mention any other details that might be useful

That behavior is caused by the following method invocations, which turn off the usage of the provided host:

if (this._webpackCompilerHost.fileExists(path, false)) {

if (this._webpackCompilerHost.fileExists(path, false)) {

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants