angular / angular/angular-cli

Build process hook

Open
#11,787 24 comments 78 reactions 0 assignees View on GitHub
area: @angular-devkit/build-angular feature feature: under consideration
Dominant language
TypeScript
Stars
27k
Forks
11.8k
Avg merge
14h 23m
Merged PRs (30d)
162

Description

### Desired functionality
It would be nice to have a hook in the build process, between the index generation and the hash computation, for execute something.

I try to use the Critical lib with my Angular project. First, I build my app, then I use Critical script in order to inline my CSS in the index file : I rewrite my index file. It was messed up with Angular SW, so I submit an issue in Angular's Github (https://github.com/angular/angular/issues/25267).

@gkalpak explains that the issue result from the stored hash mismatch, because of the rewrite of index file.

Contributor guide

Open the contributing guide

Research direction

Start by tracing the Angular CLI build process from index generation through hash computation. Verify where a hook could run between those stages, then confirm that executing a post-generation action before hashing preserves the final index hash and resolves the Angular service-worker mismatch described in the issue.

Written by the indexing model from the issue text.

Assessment

Tech stack
angular, typescript
Domain
build-system
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.